API Documentation

Server/Interface.php

Interfaces
category
Zend
copyright
Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
license
http://framework.zend.com/license/new-bsd New BSD License
package
Zend_Server
Interfaces
Zend_Server_Interface

Description

Zend Framework

LICENSE

This source file is subject to the new BSD license that is bundled with this package in the file LICENSE.txt. It is also available through the world-wide-web at this URL: http://framework.zend.com/license/new-bsd If you did not receive a copy of the license and are unable to obtain it through the world-wide-web, please send an email to license@zend.com so we can send you a copy immediately.

Zend_Server_Interface

category
Zend
copyright
Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
license
http://framework.zend.com/license/new-bsd New BSD License
package
Zend_Server
version
$Id: Interface.php 20096 2010-01-06 02:05:09Z bkarwin $
Methods
addFunction
setClass
fault
handle
getFunctions
loadFunctions
setPersistence

Description

Zend_Server_Interface

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.

Arguments
$function
string
$namespace
string
Details
visibility
public
final
false
static
false

fault

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

Generate a server fault

Arguments
$fault
mixed
$code
int
Output
mixed
Details
visibility
public
final
false
static
false

getFunctions

getFunctions( ) : array

Return a server definition array

Returns a server definition array as created using {@link * Zend_Server_Reflection}. Can be used for server introspection, documentation, or persistence.

Output
array
Details
visibility
public
final
false
static
false
access
public

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

Arguments
$request
mixed
Output
mixed
Details
visibility
public
final
false
static
false

loadFunctions

loadFunctions(  $definition ) : void

Load server definition

Used for persistence; loads a construct as returned by {@link getFunctions()}.

Arguments
$definition
Details
visibility
public
final
false
static
false

setClass

setClass( mixed $class, string $namespace, null|array $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.

Arguments
$class
mixed
Class name or object instance to examine and attach to the server.
$namespace
string
Optional namespace with which to prepend method names in the dispatch table. methods in the class will be valid callbacks.
$argv
nullarray
Optional array of arguments to pass to callbacks at dispatch.
Details
visibility
public
final
false
static
false

setPersistence

setPersistence( int $mode ) : void

Set server persistence

Arguments
$mode
int
Details
visibility
public
final
false
static
false
todo
Determine how to implement this
Documentation was generated by DocBlox.