This commit is contained in:
Dave Hulbert
2013-05-09 10:10:54 +02:00
parent 16e2cbcfcd
commit f207444307

View File

@@ -74,11 +74,11 @@ class XmlDecorator implements WebserviceDecorator
{ {
public function renderData($data) public function renderData($data)
{ {
// do some fany conversion to xml from array ... // do some fancy conversion to xml from array ...
return simplexml_load_string($data); return simplexml_load_string($data);
} }
} }
$service = new Webservice(array('foo' => 'bar')); $service = new Webservice(array('foo' => 'bar'));
$service->addDecorator(new JsonDecorator()); $service->addDecorator(new JsonDecorator());
echo $service->renderData(); echo $service->renderData();