From f93facdf082b57bbe6af9dc544b1c8c302035ed4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Elan=20Ruusam=C3=A4e?= Date: Thu, 30 Apr 2015 14:40:10 +0300 Subject: [PATCH] add implementation independent method to encode value as base64 --- class.Eventum_RPC.php | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/class.Eventum_RPC.php b/class.Eventum_RPC.php index 0f7a69a..95e7a82 100644 --- a/class.Eventum_RPC.php +++ b/class.Eventum_RPC.php @@ -76,6 +76,16 @@ public function setCredentials($username, $password) $this->client->setCredentials($username, $password); } + /** + * Implementation independent method to encode value as binary + * + * @param mixed $value + * @return XML_RPC_Value + */ + public function encodeBinary($value) { + return new XML_RPC_Value($value, 'base64'); + } + private function getClient() { $data = parse_url($this->url);