]> git.mxchange.org Git - hub.git/blobdiff - application/hub/main/template/answer/dht/class_XmlDhtBootstrapAnswerTemplateEngine.php
Continued rewriting:
[hub.git] / application / hub / main / template / answer / dht / class_XmlDhtBootstrapAnswerTemplateEngine.php
index aaeaa6e653ec9807fee2e79fb3fde95382e33e9e..f5e26d7a36f659560b1910d608b772389f599043 100644 (file)
@@ -26,12 +26,12 @@ class XmlDhtBootstrapAnswerTemplateEngine extends BaseXmlAnswerTemplateEngine im
        /**
         * Some XML nodes must be available for later data extraction
         */
-       const DHT_BOOTSTRAP_DATA_SESSION_ID    = 'my-session-id';
-       const DHT_BOOTSTRAP_DATA_NODE_STATUS   = 'my-status';
-       const DHT_BOOTSTRAP_DATA_EXTERNAL_IP   = 'my-external-ip';
-       const DHT_BOOTSTRAP_DATA_INTERNAL_IP   = 'my-internal-ip';
-       const DHT_BOOTSTRAP_DATA_LISTEN_PORT   = 'my-listen-port';
-       const DHT_BOOTSTRAP_DATA_NODE_LIST     = 'dht-nodes-list';
+       const DHT_BOOTSTRAP_DATA_SESSION_ID       = 'my-session-id';
+       const DHT_BOOTSTRAP_DATA_NODE_STATUS      = 'my-status';
+       const DHT_BOOTSTRAP_DATA_EXTERNAL_ADDRESS = 'my-external-address';
+       const DHT_BOOTSTRAP_DATA_INTERNAL_ADDRESS = 'my-internal-address';
+       const DHT_BOOTSTRAP_DATA_LISTEN_PORT      = 'my-listen-port';
+       const DHT_BOOTSTRAP_DATA_NODE_LIST        = 'dht-nodes-list';
 
        /**
         * Protected constructor
@@ -48,14 +48,14 @@ class XmlDhtBootstrapAnswerTemplateEngine extends BaseXmlAnswerTemplateEngine im
                        'my-data',
                        'your-data',
                        // Data from *this* node
-                       self::DHT_BOOTSTRAP_DATA_EXTERNAL_IP,
-                       self::DHT_BOOTSTRAP_DATA_INTERNAL_IP,
+                       self::DHT_BOOTSTRAP_DATA_EXTERNAL_ADDRESS,
+                       self::DHT_BOOTSTRAP_DATA_INTERNAL_ADDRESS,
                        self::DHT_BOOTSTRAP_DATA_LISTEN_PORT,
                        self::DHT_BOOTSTRAP_DATA_NODE_STATUS,
                        self::DHT_BOOTSTRAP_DATA_SESSION_ID,
                        // Data from other node
-                       'your-external-ip',
-                       'your-internal-ip',
+                       'your-external-address',
+                       'your-internal-address',
                        'your-session-id',
                        // Answer status (generic field)
                        self::ANSWER_STATUS,
@@ -141,23 +141,23 @@ class XmlDhtBootstrapAnswerTemplateEngine extends BaseXmlAnswerTemplateEngine im
        }
 
        /**
-        * Starts the my-external-ip
+        * Starts the my-external-address
         *
         * @return      void
         */
-       protected function startMyExternalIp () {
+       protected function startMyExternalAddress () {
                // Push the node name on the stacker
-               $this->getStackInstance()->pushNamed('node_dht_bootstrap_answer', self::DHT_BOOTSTRAP_DATA_EXTERNAL_IP);
+               $this->getStackInstance()->pushNamed('node_dht_bootstrap_answer', self::DHT_BOOTSTRAP_DATA_EXTERNAL_ADDRESS);
        }
 
        /**
-        * Starts the my-internal-ip
+        * Starts the my-internal-address
         *
         * @return      void
         */
-       protected function startMyInternalIp () {
+       protected function startMyInternalAddress () {
                // Push the node name on the stacker
-               $this->getStackInstance()->pushNamed('node_dht_bootstrap_answer', self::DHT_BOOTSTRAP_DATA_INTERNAL_IP);
+               $this->getStackInstance()->pushNamed('node_dht_bootstrap_answer', self::DHT_BOOTSTRAP_DATA_INTERNAL_ADDRESS);
        }
 
        /**
@@ -241,21 +241,21 @@ class XmlDhtBootstrapAnswerTemplateEngine extends BaseXmlAnswerTemplateEngine im
        }
 
        /**
-        * Finishes the my-internal-ip
+        * Finishes the my-internal-address
         *
         * @return      void
         */
-       protected function finishMyInternalIp () {
+       protected function finishMyInternalAddress () {
                // Pop the last entry
                $this->getStackInstance()->popNamed('node_dht_bootstrap_answer');
        }
 
        /**
-        * Finishes the my-external-ip
+        * Finishes the my-external-address
         *
         * @return      void
         */
-       protected function finishMyExternalIp () {
+       protected function finishMyExternalAddress () {
                // Pop the last entry
                $this->getStackInstance()->popNamed('node_dht_bootstrap_answer');
        }
@@ -281,23 +281,23 @@ class XmlDhtBootstrapAnswerTemplateEngine extends BaseXmlAnswerTemplateEngine im
        }
 
        /**
-        * Starts the your-external-ip
+        * Starts the your-external-address
         *
         * @return      void
         */
-       protected function startYourExternalIp () {
+       protected function startYourExternalAddress () {
                // Push the node name on the stacker
-               $this->getStackInstance()->pushNamed('node_dht_bootstrap_answer', 'your-external-ip');
+               $this->getStackInstance()->pushNamed('node_dht_bootstrap_answer', 'your-external-address');
        }
 
        /**
-        * Starts the your-internal-ip
+        * Starts the your-internal-address
         *
         * @return      void
         */
-       protected function startYourInternalIp () {
+       protected function startYourInternalAddress () {
                // Push the node name on the stacker
-               $this->getStackInstance()->pushNamed('node_dht_bootstrap_answer', 'your-internal-ip');
+               $this->getStackInstance()->pushNamed('node_dht_bootstrap_answer', 'your-internal-address');
        }
 
        /**
@@ -321,21 +321,21 @@ class XmlDhtBootstrapAnswerTemplateEngine extends BaseXmlAnswerTemplateEngine im
        }
 
        /**
-        * Finishes the your-internal-ip
+        * Finishes the your-internal-address
         *
         * @return      void
         */
-       protected function finishYourInternalIp () {
+       protected function finishYourInternalAddress () {
                // Pop the last entry
                $this->getStackInstance()->popNamed('node_dht_bootstrap_answer');
        }
 
        /**
-        * Finishes the your-external-ip
+        * Finishes the your-external-address
         *
         * @return      void
         */
-       protected function finishYourExternalIp () {
+       protected function finishYourExternalAddress () {
                // Pop the last entry
                $this->getStackInstance()->popNamed('node_dht_bootstrap_answer');
        }