\Zend_Server_Interface

Zend_Server_Interface

Summary

Methods
Constants
addFunction()
setClass()
fault()
handle()
getFunctions()
loadFunctions()
setPersistence()
No constants found
No protected methods found
N/A
No private methods found
N/A

Methods

addFunction()

addFunction(string  $function, string  $namespace = '') : void

Attach a function as a server method

Namespacing is primarily for xmlrpc, but may be used with other implementations to prevent naming collisions.

Parameters

string $function
string $namespace

setClass()

setClass(mixed  $class, string  $namespace = '',   $argv = null) : void

Attach a class to a server

The individual implementations should probably allow passing a variable number of arguments in, so that developers may define custom runtime arguments to pass to server methods.

Namespacing is primarily for xmlrpc, but could be used for other implementations as well.

Parameters

mixed $class

Class name or object instance to examine and attach to the server.

string $namespace

Optional namespace with which to prepend method names in the dispatch table. methods in the class will be valid callbacks.

$argv

fault()

fault(mixed  $fault = null, integer  $code = 404) : mixed

Generate a server fault

Parameters

mixed $fault
integer $code

Returns

mixed

handle()

handle(mixed  $request = false) : mixed

Handle a request

Requests may be passed in, or the server may automagically determine the request based on defaults. Dispatches server request to appropriate method and returns a response

Parameters

mixed $request

Returns

mixed

getFunctions()

getFunctions() : array

Return a server definition array

Returns a server definition array as created using *. Can be used for server introspection, documentation, or persistence.

Returns

array

loadFunctions()

loadFunctions(  $definition) : void

Load server definition

Used for persistence; loads a construct as returned by \getFunctions().

Parameters

$definition

setPersistence()

setPersistence(integer  $mode) : void

Set server persistence

Parameters

integer $mode