From: Roland Häder Date: Wed, 2 Dec 2020 00:30:05 +0000 (+0100) Subject: Continued: X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=65eb0629dc49b62110abbaaf69600adc49b41f0a;p=hub.git Continued: - REFACTURING: imported new traits, will have more in the future - updated core framework Signed-off-by: Roland Häder --- diff --git a/application/hub/classes/helper/connection/class_BaseConnectionHelper.php b/application/hub/classes/helper/connection/class_BaseConnectionHelper.php index 95fc8e305..3bfc8d1c2 100644 --- a/application/hub/classes/helper/connection/class_BaseConnectionHelper.php +++ b/application/hub/classes/helper/connection/class_BaseConnectionHelper.php @@ -20,6 +20,7 @@ use Org\Mxchange\CoreFramework\Factory\ObjectFactory; use Org\Mxchange\CoreFramework\Generic\FrameworkInterface; use Org\Mxchange\CoreFramework\Registry\GenericRegistry; use Org\Mxchange\CoreFramework\Registry\Registerable; +use Org\Mxchange\CoreFramework\Traits\Stream\Output\OutputStreamTrait; use Org\Mxchange\CoreFramework\Visitor\Visitable; use Org\Mxchange\CoreFramework\Visitor\Visitor; @@ -46,6 +47,9 @@ use Org\Mxchange\CoreFramework\Visitor\Visitor; * along with this program. If not, see . */ abstract class BaseConnectionHelper extends BaseHubSystemHelper implements Visitable, Registerable { + // Load traits + use OutputStreamTrait; + // Exception codes const EXCEPTION_UNSUPPORTED_ERROR_HANDLER = 0x9100; diff --git a/application/hub/classes/listener/class_BaseListener.php b/application/hub/classes/listener/class_BaseListener.php index ba84a870d..cffcf73ec 100644 --- a/application/hub/classes/listener/class_BaseListener.php +++ b/application/hub/classes/listener/class_BaseListener.php @@ -24,6 +24,7 @@ use Org\Mxchange\CoreFramework\Handler\Handleable; use Org\Mxchange\CoreFramework\Registry\Register; use Org\Mxchange\CoreFramework\Socket\InvalidServerSocketException; use Org\Mxchange\CoreFramework\Socket\SocketAlreadyRegisteredException; +use Org\Mxchange\CoreFramework\Traits\Iterator\IteratorTrait; use Org\Mxchange\CoreFramework\Visitor\Visitable; use Org\Mxchange\CoreFramework\Visitor\Visitor; @@ -54,6 +55,9 @@ use \LogicException; * along with this program. If not, see . */ abstract class BaseListener extends BaseHubSystem implements Visitable { + // Load traits + use IteratorTrait; + // Exception code constants const EXCEPTION_SOCKET_ALREADY_REGISTERED = 0xa01; const EXCEPTION_SOCKET_CREATION_FAILED = 0xa02; diff --git a/application/hub/classes/package/assembler/class_PackageAssembler.php b/application/hub/classes/package/assembler/class_PackageAssembler.php index 15a7095f6..8bcdfceb6 100644 --- a/application/hub/classes/package/assembler/class_PackageAssembler.php +++ b/application/hub/classes/package/assembler/class_PackageAssembler.php @@ -20,6 +20,7 @@ use Org\Mxchange\CoreFramework\Handler\Handleable; use Org\Mxchange\CoreFramework\Registry\Registerable; use Org\Mxchange\CoreFramework\Utils\String\StringUtils; use Org\Mxchange\CoreFramework\Stacker\Stackable; +use Org\Mxchange\CoreFramework\Traits\Stream\Input\InputStreamTrait; use Org\Mxchange\CoreFramework\Visitor\Visitable; use Org\Mxchange\CoreFramework\Visitor\Visitor; @@ -50,6 +51,9 @@ use \BadMethodCallException; * along with this program. If not, see . */ class PackageAssembler extends BaseHubSystem implements Assembler, Registerable, Visitable { + // Load traits + use InputStreamTrait; + /** * Name for stacker holding raw data of multiple messages */ diff --git a/application/hub/classes/producer/cruncher/keys/class_BaseKeyProducer.php b/application/hub/classes/producer/cruncher/keys/class_BaseKeyProducer.php index 644981e61..92f6ceeb4 100644 --- a/application/hub/classes/producer/cruncher/keys/class_BaseKeyProducer.php +++ b/application/hub/classes/producer/cruncher/keys/class_BaseKeyProducer.php @@ -5,6 +5,9 @@ namespace Org\Shipsimu\Hub\Producer\Cruncher\Key; // Import application-specific stuff use Org\Shipsimu\Hub\Producer\Cruncher\BaseCruncherProducer; +// Import framework stuff +use Org\Mxchange\CoreFramework\Traits\Iterator\IteratorTrait; + /** * A general KeyProducer class * @@ -28,6 +31,9 @@ use Org\Shipsimu\Hub\Producer\Cruncher\BaseCruncherProducer; * along with this program. If not, see . */ abstract class BaseKeyProducer extends BaseCruncherProducer { + // Load traits + use IteratorTrait; + /** * Protected constructor * diff --git a/core b/core index 977b9bbb8..9a7a272f0 160000 --- a/core +++ b/core @@ -1 +1 @@ -Subproject commit 977b9bbb804eda74ad2d819d1de082933dd0bb08 +Subproject commit 9a7a272f04e54537aaf30c282598c1742fe0ad88