1638. Class

1638.1. Zend\XmlRpc\Server\Fault

XMLRPC Server Faults

Encapsulates an exception for use as an XMLRPC fault response. Valid exception classes that may be used for generating the fault code and fault string can be attached using {@link attachFaultException()}; all others use a generic ‘404 Unknown error’ response.

You may also attach fault observers, which would allow you to monitor particular fault cases; this is done via {@link attachObserver()}. Observers need only implement a static ‘observe’ method.

To allow method chaining, you may use the {@link getInstance()} factory to instantiate a Zend_XmlRpc_Server_Fault.

1638.1.1. Methods

1638.1.1.1. __construct

__construct()

Constructor

Parameters:Exception
Return type:Fault

1638.1.1.2. getInstance

getInstance()

Return ZendXmlRpcServerFault instance

Parameters:Exception
Return type:Fault

1638.1.1.3. attachFaultException

attachFaultException()

Attach valid exceptions that can be used to define xmlrpc faults

Parameters:string|array – Class name or array of class names
Return type:void

1638.1.1.4. detachFaultException

detachFaultException()

Detach fault exception classes

Parameters:string|array – Class name or array of class names
Return type:void

1638.1.1.5. attachObserver

attachObserver()

Attach an observer class

Allows observation of xmlrpc server faults, thus allowing logging or mail notification of fault responses on the xmlrpc server.

Expects a valid class name; that class must have a public static method ‘observe’ that accepts an exception as its sole argument.

Parameters:string
Return type:bool

1638.1.1.6. detachObserver

detachObserver()

Detach an observer

Parameters:string
Return type:bool

1638.1.1.7. getException

getException()

Retrieve the exception

Return type:Exception