|
Moodle
2.2.1
http://www.collinsharper.com
|


Public Member Functions | |
| __construct ($authmethod) | |
Static Public Member Functions | |
| static | validate_and_cast_values ($description, $value) |
Protected Member Functions | |
| init_service_class () | |
| service_class_method_body ($function, $params) | |
| init_zend_server () | |
AMF service server implementation.
Definition at line 47 of file locallib.php.
| __construct | ( | $ | authmethod | ) |
Contructor
| integer | $authmethod | authentication method - one of WEBSERVICE_AUTHMETHOD_* |
Reimplemented from webservice_server.
Definition at line 52 of file locallib.php.
| init_service_class | ( | ) | [protected] |
Load virtual class needed for Zend api
Reimplemented from webservice_zend_server.
Definition at line 56 of file locallib.php.
| init_zend_server | ( | ) | [protected] |
Set up zend service class
Reimplemented from webservice_zend_server.
Definition at line 154 of file locallib.php.
| service_class_method_body | ( | $ | function, |
| $ | params | ||
| ) | [protected] |
You can override this function in your child class to add extra code into the dynamically created service class. For example it is used in the amf server to cast types of parameters and to cast the return value to the types as specified in the return value description.
| stdClass | $function | |
| array | $params |
Reimplemented from webservice_zend_server.
Definition at line 63 of file locallib.php.
| static validate_and_cast_values | ( | $ | description, |
| $ | value | ||
| ) | [static] |
Validates submitted value, comparing it to a description. If anything is incorrect invalid_return_value_exception is thrown. Also casts the values to the type specified in the description.
| mixed | $description | description of parameters or null if no return value |
| mixed | $value | the actual values |
| boolean | $singleasobject | specifies whether a external_single_structure should be cast to a stdClass object should always be false for use in validating parameters in externallib functions. |
Definition at line 92 of file locallib.php.
