__construct()
__toString()
addParam()
getEncoding()
getFault()
getMethod()
getParams()
getTypes()
isFault()
loadXml()
saveXml()
setEncoding()
setMethod()
setParams()
_getXmlRpcParams()
$encoding
$fault
$method
$params
$types
$xml
$xmlRpcParams
XmlRpc Request object
Encapsulates an XmlRpc request, holding the method call and all parameters. Provides accessors for these, as well as the ability to load from XML and to create the XML request string.
Additionally, if errors occur setting the method or parsing XML, a fault is generated and stored in $fault; developers may check for it using isFault() and getFault().
__construct(string $method, array $params)
string(optional)
array(optional)
__toString() : string
stringaddParam(mixed $value, string $type) : void
Adds a parameter to the parameter stack, associating it with the type $type if provided
mixed
stringOptional; type hinting
getEncoding() : string
stringgetMethod() : string
stringgetParams() : array
arraygetTypes() : array
arrayisFault() : bool
boolloadXml(string $request) : bool
string
\Zend\XmlRpc\Exception\ValueException |
if invalid XML |
|---|
boolTrue on success, false if an error occurred.saveXml() : string
stringsetMethod(string $method) : bool
string
boolReturns true on success, false if method name is invalidsetParams() : void
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
)[, ... ]
);
| access | public |
|---|
_getXmlRpcParams() : array
array$encoding : string
$method : string
$params : array
$types : array
$xml : string
$xmlRpcParams : array