*
* @author Roland Haeder <webmaster@shipsimu.org>
* @version 0.0.0
- * @copyright Copyright (c) 2007, 2008 Roland Haeder, 2009 - 2014 Core Developer Team
+ * @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
* @todo This template engine does not make use of setTemplateType()
/**
* Some XML nodes must be available for later data extraction
*/
- const DHT_BOOTSTRAP_DATA_BOOTSTRAP_DATA = 'dht-bootstrap-data';
- const DHT_BOOTSTRAP_DATA_SESSION_ID = 'session-id';
- const DHT_BOOTSTRAP_DATA_NODE_STATUS = 'node-status';
- const DHT_BOOTSTRAP_DATA_NODE_MODE = 'node-mode';
- const DHT_BOOTSTRAP_DATA_EXTERNAL_IP = 'external-ip';
- const DHT_BOOTSTRAP_DATA_INTERNAL_IP = 'internal-ip';
- const DHT_BOOTSTRAP_DATA_LISTEN_PORT = 'listen-port';
+ const DHT_BOOTSTRAP_DATA_BOOTSTRAP_DATA = 'dht-bootstrap-data';
+ const DHT_BOOTSTRAP_DATA_SESSION_ID = 'session-id';
+ const DHT_BOOTSTRAP_DATA_NODE_STATUS = 'node-status';
+ const DHT_BOOTSTRAP_DATA_NODE_MODE = 'node-mode';
+ const DHT_BOOTSTRAP_DATA_EXTERNAL_ADDRESS = 'external-address';
+ const DHT_BOOTSTRAP_DATA_INTERNAL_ADDRESS = 'internal-address';
/**
* Protected constructor
parent::__construct(__CLASS__);
// Init array
- $this->subNodes = array(
+ $this->setSubNodes(array(
self::DHT_BOOTSTRAP_DATA_BOOTSTRAP_DATA,
'listener',
self::DHT_BOOTSTRAP_DATA_NODE_STATUS,
self::DHT_BOOTSTRAP_DATA_NODE_MODE,
- self::DHT_BOOTSTRAP_DATA_LISTEN_PORT,
self::DHT_BOOTSTRAP_DATA_SESSION_ID,
- self::DHT_BOOTSTRAP_DATA_EXTERNAL_IP,
- self::DHT_BOOTSTRAP_DATA_INTERNAL_IP
- );
+ self::DHT_BOOTSTRAP_DATA_EXTERNAL_ADDRESS,
+ self::DHT_BOOTSTRAP_DATA_INTERNAL_ADDRESS
+ ));
}
/**
$this->getStackInstance()->pushNamed('dht_bootstrap', 'listener');
}
- /**
- * Starts the TCP/UDP listen port
- *
- * @return void
- */
- protected function startListenPort () {
- // Push the node name on the stacker
- $this->getStackInstance()->pushNamed('dht_bootstrap', self::DHT_BOOTSTRAP_DATA_LISTEN_PORT);
- }
-
/**
* Starts the public ip
*
* @return void
*/
- protected function startExternalIp () {
+ protected function startExternalAddress () {
// Push the node name on the stacker
- $this->getStackInstance()->pushNamed('dht_bootstrap', self::DHT_BOOTSTRAP_DATA_EXTERNAL_IP);
+ $this->getStackInstance()->pushNamed('dht_bootstrap', self::DHT_BOOTSTRAP_DATA_EXTERNAL_ADDRESS);
}
/**
*
* @return void
*/
- protected function startInternalIp () {
+ protected function startInternalAddress () {
// Push the node name on the stacker
- $this->getStackInstance()->pushNamed('dht_bootstrap', self::DHT_BOOTSTRAP_DATA_INTERNAL_IP);
+ $this->getStackInstance()->pushNamed('dht_bootstrap', self::DHT_BOOTSTRAP_DATA_INTERNAL_ADDRESS);
}
/**
*
* @return void
*/
- protected function finishInternalIp () {
+ protected function finishInternalAddress () {
// Pop the last entry
$this->getStackInstance()->popNamed('dht_bootstrap');
}
*
* @return void
*/
- protected function finishExternalIp () {
- // Pop the last entry
- $this->getStackInstance()->popNamed('dht_bootstrap');
- }
-
- /**
- * Finishes the TCP/UDP listen port
- *
- * @return void
- */
- protected function finishListenPort () {
+ protected function finishExternalAddress () {
// Pop the last entry
$this->getStackInstance()->popNamed('dht_bootstrap');
}