summaryrefslogtreecommitdiff
path: root/lib/exe/xmlrpc.php
diff options
context:
space:
mode:
authorDominik Eckelmann <deckelmann@gmail.com>2012-01-08 18:37:59 +0100
committerDominik Eckelmann <deckelmann@gmail.com>2012-01-08 18:37:59 +0100
commitf95017850a515969190f54df3d57a00449245bb9 (patch)
treedf96b4aded1c318703093cb6b7426a38b0d25ba8 /lib/exe/xmlrpc.php
parent1232df5e9480465ff8b2e24ce5760766b3bd908c (diff)
downloadrpg-f95017850a515969190f54df3d57a00449245bb9.tar.gz
rpg-f95017850a515969190f54df3d57a00449245bb9.tar.bz2
delegate file and date transformation to remote library
Diffstat (limited to 'lib/exe/xmlrpc.php')
-rw-r--r--lib/exe/xmlrpc.php10
1 files changed, 10 insertions, 0 deletions
diff --git a/lib/exe/xmlrpc.php b/lib/exe/xmlrpc.php
index 9888c9a61..44b4ba7a0 100644
--- a/lib/exe/xmlrpc.php
+++ b/lib/exe/xmlrpc.php
@@ -27,6 +27,8 @@ class dokuwiki_xmlrpc_server extends IXR_Server {
*/
function dokuwiki_xmlrpc_server(){
$this->remote = new RemoteAPI();
+ $this->remote->setDateTransformation(array($this, 'toDate'));
+ $this->remote->setFileTransformation(array($this, 'toFile'));
$this->IXR_Server();
}
@@ -47,6 +49,14 @@ class dokuwiki_xmlrpc_server extends IXR_Server {
}
}
+ function toDate($data) {
+ return new IXR_Date($data);
+ }
+
+ function toFile($data) {
+ return new IXR_Base64($data);
+ }
+
}
$server = new dokuwiki_xmlrpc_server();