]> git.mxchange.org Git - hub.git/commitdiff
Next wave:
authorRoland Häder <roland@mxchange.org>
Fri, 19 May 2017 14:37:08 +0000 (16:37 +0200)
committerRoland Häder <roland@mxchange.org>
Fri, 21 Aug 2020 16:50:01 +0000 (18:50 +0200)
- imported BaseDiscovery, Discoveryable, BaseNodeDiscovery
- created namespaces
- removed duplicate interface, now in core framework
- BaseNodeDiscovery needs to be abstract now
- added missing namespaces
- no, no. BaseNodeDiscovery must implement the generic methods
- tpzo fixed

Signed-off-by: Roland Häder <roland@mxchange.org>
application/hub/classes/discovery/class_
application/hub/classes/discovery/class_BaseNodeDiscovery.php
application/hub/classes/discovery/node/class_UniversalNodeLocatorDiscovery.php
application/hub/classes/discovery/protocol/class_ProtocolDiscovery.php
application/hub/classes/discovery/recipient/class_BaseRecipientDiscovery.php
application/hub/config.php
application/hub/interfaces/discovery/class_Discoverable
application/hub/interfaces/discovery/class_Discoverable.php [deleted file]
application/hub/interfaces/discovery/protocol/class_DiscoverableProtocol.php
application/hub/interfaces/discovery/recipient/class_DiscoverableRecipient.php
application/hub/interfaces/discovery/unl/class_DiscoverableUniversalNodeLocator.php

index fc0d85a69142fab1a29909444e6f3dd4aa3f9192..1358479198993d6fd0a4963137e83b31965e3e90 100644 (file)
@@ -1,4 +1,7 @@
 <?php
+// Own namespace
+namespace Hub\Discovery\;
+
 /**
  * A !!! discovery class
  *
index 8da4919404661a1fbd0e37fae27ec205e524927c..57c8d96c308b648c7b4e940b70752c49abfcb2aa 100644 (file)
@@ -1,4 +1,11 @@
 <?php
+// Own namespace
+namespace Hub\Discovery\Node;
+
+// Import framework stuff
+use CoreFramework\Discovery\BaseDiscovery;
+use CoreFramework\Discovery\Discoverable;
+
 /**
  * A general node discovery class
  *
@@ -32,4 +39,5 @@ class BaseNodeDiscovery extends BaseDiscovery implements Discoverable {
                // Call parent constructor
                parent::__construct($className);
        }
+
 }
index d11b0bfd401ce4e3d8b237474a76a6680db77baa..73f162d6fa2b328f021b14f6a2993b95e449642b 100644 (file)
@@ -1,8 +1,9 @@
 <?php
 // Own namespace
-namespace Hub\Disovery\Locator;
+namespace Hub\Discovery\Locator;
 
 // Import application-specific stuff
+use Hub\Discovery\Node\BaseNodeDiscovery;
 use Hub\Helper\Node\NodeHelper;
 
 // Import framework stuff
index 0537f902b04c41d781244def0b53b6387893dce6..ca5a6485247dced794d81ad0a57dc959aa9504a1 100644 (file)
@@ -2,6 +2,9 @@
 // Own namespace
 namespace Hub\Discovery\Protocol;
 
+// Import application-specific stuff
+use Hub\Discovery\Node\BaseNodeDiscovery;
+
 // Import framework stuff
 use CoreFramework\Registry\Registerable;
 
index 9ad0f612e0c7bc52fee84423c0e1a2ec53049780..cc9ff9c0c6579828819adabc9f7a38ad4b65866c 100644 (file)
@@ -1,4 +1,10 @@
 <?php
+// Own namespace
+namespace Hub\Discovery\Recipient;
+
+// Import framework-specific stuff
+use Hub\Discovery\Node\BaseNodeDiscovery;
+
 /**
  * A PackageRecipient discovery class
  *
@@ -76,7 +82,5 @@ class BaseRecipientDiscovery extends BaseNodeDiscovery implements DiscoverableRe
                // Return it
                return $isEmpty;
        }
-}
 
-// [EOF]
-?>
+}
index bfeff2932ede20f9ce13a751d93e9bf1ae430d8b..a45a14971b9a11bade7dc83eda603177371875b1 100644 (file)
@@ -724,7 +724,7 @@ $cfg->setConfigEntry('socket_discovery_class', 'PackageSocketDiscovery');
 $cfg->setConfigEntry('dht_recipient_discovery_class', 'DhtRecipientDiscovery');
 
 // CFG: UNL-DISCOVERY-CLASS
-$cfg->setConfigEntry('unl_discovery_class', 'UniversalNodeLocatorDiscovery');
+$cfg->setConfigEntry('unl_discovery_class', 'Hub\Discovery\Locator\UniversalNodeLocatorDiscovery');
 
 // CFG: TCP-PROTOCOL-HANDLER-CLASS
 $cfg->setConfigEntry('tcp_protocol_handler_class', 'TcpProtocolHandler');
index ebe26957b00422dd3e14b87ba78a50348be7f6cb..ec04796e5fdc56477180a245a2aa777c2ae58b95 100644 (file)
@@ -1,4 +1,10 @@
 <?php
+// Own namespace
+namespace Hub\Discovery\;
+
+// Import framework stuff
+use CoreFramework\Discovery\Discoverable;
+
 /**
  * An interface for !!! discovery
  *
diff --git a/application/hub/interfaces/discovery/class_Discoverable.php b/application/hub/interfaces/discovery/class_Discoverable.php
deleted file mode 100644 (file)
index 478b8cb..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-<?php
-// Own namespace
-namespace Hub\Discovery;
-
-// Import framework stuff
-use CoreFramework\Generic\FrameworkInterface;
-
-/**
- * An interface for socket discovery
- *
- * @author             Roland Haeder <webmaster@shipsimu.org>
- * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 - 2015 Hub Developer Team
- * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.shipsimu.org
- *
- * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program. If not, see <http://www.gnu.org/licenses/>.
- */
-interface Discoverable extends FrameworkInterface {
-}
-
-// [EOF]
-?>
index e60cac53c74e9b8cf121469386d3df44683bf623..e002399c80da034d4599ea7698bc4902627c6799 100644 (file)
@@ -1,4 +1,10 @@
 <?php
+// Own namespace
+namespace Hub\Discovery\Protocol;
+
+// Import framework stuff
+use CoreFramework\Discovery\Discoverable;
+
 /**
  * An interface for protocol discovery
  *
index 66ccd1cf35e075054e024aaa379b3dbbac1991e8..60fc50955f57eba4bd203a1d2fa97f8faeb8c7b6 100644 (file)
@@ -1,4 +1,10 @@
 <?php
+// Own namespace
+namespace Hub\Discovery\Recipient;
+
+// Import framework stuff
+use CoreFramework\Discovery\Discoverable;
+
 /**
  * An interface for recipient discovery
  *
index 4843ba25aa24a6553c2d66ce6e8ce2cf90270d7f..4b83d41f7b8e80ad1608021e49222cd9e8433a9c 100644 (file)
@@ -5,6 +5,9 @@ namespace Hub\Discovery\Locator;
 // Import application-specific stuff
 use Hub\Helper\Node\NodeHelper;
 
+// Import framework stuff
+use CoreFramework\Discovery\Discoverable;
+
 /**
  * An interface for UNL discovery
  *