From f0c7712f866a88d892949053407e420e405a73d1 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Fri, 19 May 2017 18:35:06 +0200 Subject: [PATCH] Next wave: - imported HubHelper - created namespaces MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Roland Häder --- .../factories/handler/class_ProtocolHandlerFactory.php | 7 ++++--- .../hub/classes/package/class_NetworkPackage.php | 5 ++--- .../helper/connections/class_ConnectionHelper.php | 3 +++ .../hub/interfaces/helper/dht/class_HelpableDht.php | 10 +++++++--- .../hub/interfaces/helper/hub/class_HubHelper.php | 4 +--- .../hub/interfaces/helper/node/class_HelpableNode.php | 5 ++--- .../hub/interfaces/package/class_Deliverable.php | 7 ++++--- 7 files changed, 23 insertions(+), 18 deletions(-) diff --git a/application/hub/classes/factories/handler/class_ProtocolHandlerFactory.php b/application/hub/classes/factories/handler/class_ProtocolHandlerFactory.php index e631b0a14..685d6acd7 100644 --- a/application/hub/classes/factories/handler/class_ProtocolHandlerFactory.php +++ b/application/hub/classes/factories/handler/class_ProtocolHandlerFactory.php @@ -2,6 +2,9 @@ // Own namespace namespace Hub\Factory\Handler\Protocol; +// Import application-specific stuff +use Hub\Helper\HubHelper; + // Import framework stuff use CoreFramework\Factory\ObjectFactory; use CoreFramework\Registry\Registry; @@ -92,7 +95,5 @@ class ProtocolHandlerFactory extends ObjectFactory { // Call super factory method return self::createProtocolHandlerByType($protocolType); } -} -// [EOF] -?> +} diff --git a/application/hub/classes/package/class_NetworkPackage.php b/application/hub/classes/package/class_NetworkPackage.php index b245f7b88..27bef5da9 100644 --- a/application/hub/classes/package/class_NetworkPackage.php +++ b/application/hub/classes/package/class_NetworkPackage.php @@ -9,6 +9,7 @@ use Hub\Factory\Node\NodeObjectFactory; use Hub\Generic\BaseHubSystem; use Hub\Helper\Connection\BaseConnectionHelper; use Hub\Helper\Connection\ConnectionHelper; +use Hub\Helper\HubHelper; use Hub\Network\Receive\Receivable; use Hub\Tools\HubTools; @@ -1527,7 +1528,5 @@ class NetworkPackage extends BaseHubSystem implements Deliverable, Receivable, R $this->partialStub('@TODO nodeId=' . $nodeId . ',messageData=' . print_r($messageData, TRUE)); } -} -// [EOF] -?> +} diff --git a/application/hub/interfaces/helper/connections/class_ConnectionHelper.php b/application/hub/interfaces/helper/connections/class_ConnectionHelper.php index efde02fa3..fbbc630ca 100644 --- a/application/hub/interfaces/helper/connections/class_ConnectionHelper.php +++ b/application/hub/interfaces/helper/connections/class_ConnectionHelper.php @@ -2,6 +2,9 @@ // Own namespace namespace Hub\Helper\Connection; +// Import application-specific stuff +use Hub\Helper\HubHelper; + /** * An interface for connection helper classes * diff --git a/application/hub/interfaces/helper/dht/class_HelpableDht.php b/application/hub/interfaces/helper/dht/class_HelpableDht.php index 2da84313e..b208b74bf 100644 --- a/application/hub/interfaces/helper/dht/class_HelpableDht.php +++ b/application/hub/interfaces/helper/dht/class_HelpableDht.php @@ -1,4 +1,10 @@ +} diff --git a/application/hub/interfaces/helper/hub/class_HubHelper.php b/application/hub/interfaces/helper/hub/class_HubHelper.php index ff98b0eeb..f036ed444 100644 --- a/application/hub/interfaces/helper/hub/class_HubHelper.php +++ b/application/hub/interfaces/helper/hub/class_HubHelper.php @@ -34,7 +34,5 @@ interface HubHelper extends Helper { * @return $protocolType Type of protocol to use, usually TCP */ function determineProtocolType (); -} -// [EOF] -?> +} diff --git a/application/hub/interfaces/helper/node/class_HelpableNode.php b/application/hub/interfaces/helper/node/class_HelpableNode.php index 198a7a367..5ff2a0a49 100644 --- a/application/hub/interfaces/helper/node/class_HelpableNode.php +++ b/application/hub/interfaces/helper/node/class_HelpableNode.php @@ -3,6 +3,7 @@ namespace Hub\Helper\Node; // Import application-specific stuff +use Hub\Helper\HubHelper; use Hub\Helper\Node\NodeHelper; /** @@ -43,7 +44,5 @@ interface HelpableNode extends HubHelper { * @return void */ function sendPackage (NodeHelper $nodeInstance); -} -// [EOF] -?> +} diff --git a/application/hub/interfaces/package/class_Deliverable.php b/application/hub/interfaces/package/class_Deliverable.php index f2065f256..e60d9ac24 100644 --- a/application/hub/interfaces/package/class_Deliverable.php +++ b/application/hub/interfaces/package/class_Deliverable.php @@ -2,6 +2,9 @@ // Own namespace namespace Hub\Network\Deliver; +// Import application-specific stuff +use Hub\Helper\HubHelper; + // Import framework stuff use CoreFramework\Generic\FrameworkInterface; @@ -107,7 +110,5 @@ interface Deliverable extends FrameworkInterface { * @return void */ function clearAllStacks (); -} -// [EOF] -?> +} -- 2.39.5