Zend Framework  1.12
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
Zend_XmlRpc_Request Class Reference

Public Member Functions

 __construct ($method=null, $params=null)
 Create a new XML-RPC request.
 
 setEncoding ($encoding)
 Set encoding to use in request.
 
 getEncoding ()
 Retrieve current request encoding.
 
 setMethod ($method)
 Set method to call.
 
 getMethod ()
 Retrieve call method.
 
 addParam ($value, $type=null)
 Add a parameter to the parameter stack.
 
 setParams ()
 Set the parameters array.
 
 getParams ()
 Retrieve the array of parameters.
 
 getTypes ()
 Return parameter types.
 
 loadXml ($request)
 Load XML and parse into request components.
 
 isFault ()
 Does the current request contain errors and should it return a fault response?
 
 getFault ()
 Retrieve the fault response, if any.
 
 saveXml ()
 Create XML request.
 
 __toString ()
 Return XML request.
 

Protected Member Functions

 _getXmlRpcParams ()
 Retrieve method parameters as XMLRPC values.
 

Protected Attributes

 $_encoding = 'UTF-8'
 
 $_method
 
 $_xml
 
 $_params = array()
 
 $_fault = null
 
 $_types = array()
 
 $_xmlRpcParams = array()
 

Constructor & Destructor Documentation

__construct (   $method = null,
  $params = null 
)

Create a new XML-RPC request.

Parameters
string$method(optional)
array$params(optional)

Member Function Documentation

__toString ( )

Return XML request.

Returns
string
_getXmlRpcParams ( )
protected

Retrieve method parameters as XMLRPC values.

Returns
array
addParam (   $value,
  $type = null 
)

Add a parameter to the parameter stack.

Adds a parameter to the parameter stack, associating it with the type $type if provided

Parameters
mixed$value
string$typeOptional; type hinting
Returns
void
getEncoding ( )

Retrieve current request encoding.

Returns
string
getFault ( )

Retrieve the fault response, if any.

Returns
null|Zend_XmlRpc_Fault
getMethod ( )

Retrieve call method.

Returns
string
getParams ( )

Retrieve the array of parameters.

Returns
array
getTypes ( )

Return parameter types.

Returns
array
isFault ( )

Does the current request contain errors and should it return a fault response?

Returns
boolean
loadXml (   $request)

Load XML and parse into request components.

Parameters
string$request
Returns
boolean True on success, false if an error occurred.
saveXml ( )

Create XML request.

Returns
string
setEncoding (   $encoding)

Set encoding to use in request.

Parameters
string$encoding
Returns
Zend_XmlRpc_Request
setMethod (   $method)

Set method to call.

Parameters
string$method
Returns
boolean Returns true on success, false if method name is invalid
setParams ( )

Set the parameters array.

If called with a single, array value, that array is used to set the parameters stack. If called with multiple values or a single non-array value, the arguments are used to set the parameters stack.

Best is to call with array of the format, in order to allow type hinting when creating the XMLRPC values for each parameter: $array = array( array( 'value' => $value, 'type' => $type )[, ... ] );

public

Returns
void

Member Data Documentation

$_encoding = 'UTF-8'
protected
$_fault = null
protected
$_method
protected
$_params = array()
protected
$_types = array()
protected
$_xml
protected
$_xmlRpcParams = array()
protected