/** * The main method of the executive class. * * @param array $a Arguments to pass to the method * @return mixed The results from the method operation */ function doMethodCall(&$bodyObj, &$object, $method, $args) { try { $output = Executive::deferredMethodCall($bodyObj, $object, $method, $args); } catch (Exception $fault) { if (get_class($fault) == "VerboseException") { $ex = new MessageException($fault->code, $fault->getMessage(), $fault->file, $fault->line, 'AMFPHP_RUNTIME_ERROR'); } else { $code = "AMFPHP_RUNTIME_ERROR"; if ($fault->getCode() != 0) { $code = $fault->getCode(); } $ex = new MessageException(E_USER_ERROR, $fault->getMessage(), $fault->getFile(), $fault->getLine(), $code); } MessageException::throwException($bodyObj, $ex); $output = '__amfphp_error'; } return $output; }