XRL  latest
Simple XML-RPC Library (both client and server)
fpoirotte\XRL\NativeDecoder Class Reference

A decoder that transparently converts XML-RPC types to native PHP types. More...

+ Inheritance diagram for fpoirotte\XRL\NativeDecoder:

Public Member Functions

 __construct (\fpoirotte\XRL\DecoderInterface $decoder)
 
 decodeRequest ($URI)
 
 decodeResponse ($URI)
 

Protected Attributes

 $decoder
 Sub-decoder.
 

Detailed Description

A decoder that transparently converts XML-RPC types to native PHP types.

Authors
François Poirotte click.nosp@m.y@er.nosp@m.ebot..nosp@m.net

Definition at line 21 of file NativeDecoder.php.

Constructor & Destructor Documentation

fpoirotte\XRL\NativeDecoder::__construct ( \fpoirotte\XRL\DecoderInterface  $decoder)

Creates a new decoder.

Parameters
fpoirotte::XRL::DecoderInterface$decoderSub-decoder to use.

Definition at line 32 of file NativeDecoder.php.

References fpoirotte\XRL\NativeDecoder\$decoder.

Member Function Documentation

fpoirotte\XRL\NativeDecoder::decodeRequest (   $URI)

Decode an XML-RPC request.

Parameters
string$URIURI to XML-RPC request.
Return values
fpoirotte::XRL::RequestAn object representing an XML-RPC request.
Exceptions
InvalidArgumentExceptionThe given $data was invalid. For example, it wasn't a string, it didn"t contain any XML or the request was malformed.

Implements fpoirotte\XRL\DecoderInterface.

Definition at line 38 of file NativeDecoder.php.

fpoirotte\XRL\NativeDecoder::decodeResponse (   $URI)

Decode an XML-RPC response.

Parameters
string$URIURI to the XML-RPC response.
Return values
mixedThe return value represented by the XML-RPC response.
Exceptions
fpoirotte::XRL::ExceptionThrown whenever the response described a failure. This exception's getCode() and getMessage() methods can be used to retrieve the original failure's code and description, respectively.
InvalidArgumentExceptionThe given $data was invalid. For example, it wasn't a string, it didn"t contain any XML or the request was malformed.

Implements fpoirotte\XRL\DecoderInterface.

Definition at line 49 of file NativeDecoder.php.


The documentation for this class was generated from the following file: