From: Roland Häder Date: Tue, 21 Aug 2012 14:21:55 +0000 (+0000) Subject: Added XML node 'accepted-object-types', used direct BaseHubSystem instead of 'self... X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=2a06922cabf2e7f18dc5d1041d6fe60239a56e2a;p=hub.git Added XML node 'accepted-object-types', used direct BaseHubSystem instead of 'self' because BaseStream does no longer extend BaseHubSystem --- diff --git a/application/hub/main/streams/raw_data/input/class_RawDataInputStream.php b/application/hub/main/streams/raw_data/input/class_RawDataInputStream.php index a708c984e..41a4d474a 100644 --- a/application/hub/main/streams/raw_data/input/class_RawDataInputStream.php +++ b/application/hub/main/streams/raw_data/input/class_RawDataInputStream.php @@ -69,10 +69,10 @@ class RawDataInputStream extends BaseStream implements InputStreamable { // Can it be validated? if ((strlen($data) % 4) != 0) { // Length modulo 4 must be zero, else it is an invalid Base64 message - throw new Base64EncodingModuloException(array($this, $data), self::EXCEPTION_BASE64_ENCODING_NOT_MODULO_4); + throw new Base64EncodingModuloException(array($this, $data), BaseHubSystem::EXCEPTION_BASE64_ENCODING_NOT_MODULO_4); } elseif (!$this->isBase64Encoded($data)) { // Is not a valid Base64-encoded message - throw new Base64EncodingBadException(array($this, $data), self::EXCEPTION_BASE64_BAD_ENCODING); + throw new Base64EncodingBadException(array($this, $data), BaseHubSystem::EXCEPTION_BASE64_BAD_ENCODING); } else { // Decode the data with BASE64-encoding $data = base64_decode($data); diff --git a/application/hub/main/template/requests/class_XmlRequestNodeListTemplateEngine.php b/application/hub/main/template/requests/class_XmlRequestNodeListTemplateEngine.php index 968a5b928..32fc532fc 100644 --- a/application/hub/main/template/requests/class_XmlRequestNodeListTemplateEngine.php +++ b/application/hub/main/template/requests/class_XmlRequestNodeListTemplateEngine.php @@ -27,7 +27,8 @@ class XmlRequestNodeListTemplateEngine extends BaseTemplateEngine implements Com * Main nodes in the XML tree */ private $mainNodes = array( - 'node-request-node-list' + 'node-request-node-list', + 'accepted-object-types' ); /** @@ -265,6 +266,26 @@ class XmlRequestNodeListTemplateEngine extends BaseTemplateEngine implements Com $this->getStackerInstance()->pushNamed('node_request_node_list', 'node-request-node-list'); } + /** + * Starts the accepted-object-types + * + * @return void + */ + private function startAcceptedObjectTypes () { + // Push the node name on the stacker + $this->getStackerInstance()->pushNamed('node_request_node_list', 'accepted-object-types'); + } + + /** + * Finishes the accepted-object-types + * + * @return void + */ + private function finishAcceptedObjectTypes () { + // Pop the last entry + $this->getStackerInstance()->popNamed('node_request_node_list'); + } + /** * Finishes the node-request-node-list *