99 array $options = array()
102 $encoder = new \fpoirotte\XRL\NativeEncoder(
108 $decoder = new \fpoirotte\XRL\NativeDecoder(
114 $this->options = $options;
148 public function __call($method, array $args)
150 $newArgs = array_map(
'\\fpoirotte\\XRL\\NativeEncoder::convert', $args);
151 $request = new \fpoirotte\XRL\Request($method, $newArgs);
152 $xml = $this->encoder->encodeRequest($request);
155 'Content-Type: text/xml',
163 'header' => $headers,
167 $options = array_merge_recursive($this->options, $options);
168 $context = stream_context_create($options);
169 libxml_set_streams_context(
$context);
170 return $this->decoder->decodeResponse($this->baseURL);
Interface for an XML-RPC decoder.
Interface for an XML-RPC encoder.
An XML-RPC encoder that can produce either compact documents or pretty documents. ...
__construct($baseURL,\fpoirotte\XRL\EncoderInterface $encoder=null,\fpoirotte\XRL\DecoderInterface $decoder=null, array $options=array())
$encoder
Encoder for the request.
$baseURL
The remote XML-RPC server's base URL.
$decoder
Decoder for the response.
__call($method, array $args)
A decoder that can process XML-RPC requests and responses, with optional XML validation.
$context
A stream context to use when querying the server.