]> git.mxchange.org Git - hub.git/blobdiff - application/hub/main/states/node/init/class_NodeInitState.php
Updated 'core'.
[hub.git] / application / hub / main / states / node / init / class_NodeInitState.php
index 2d0092d2a6c84445417a9572072d6de55b7ed749..6f4014f17a421d3b91de0dc14625a54778731b74 100644 (file)
@@ -2,11 +2,11 @@
 /**
  * A init node state class
  *
- * @author             Roland Haeder <webmaster@ship-simu.org>
+ * @author             Roland Haeder <webmaster@shipsimu.org>
  * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009, 2010 Hub 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.ship-simu.org
+ * @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
@@ -38,19 +38,12 @@ class NodeInitState extends BaseNodeState implements Stateable {
        /**
         * Creates an instance of this class
         *
-        * @param       $nodeInstance   An instance of a NodeHelper class
         * @return      $stateInstance  An instance of a Stateable class
         */
-       public final static function createNodeInitState (NodeHelper $nodeInstance) {
+       public static final function createNodeInitState () {
                // Get new instance
                $stateInstance = new NodeInitState();
 
-               // Debug message
-               $stateInstance->debugOutput('NODE-STATE: Has changed from ' . $nodeInstance->getPrintableState() . ' to ' . $stateInstance->getStateName() . '.');
-
-               // Set the node instance
-               $stateInstance->setNodeInstance($nodeInstance);
-
                // Return the prepared instance
                return $stateInstance;
        }
@@ -58,12 +51,14 @@ class NodeInitState extends BaseNodeState implements Stateable {
        /**
         * State change for if the node has just generated a session id. This makes
         * nodes with current state 'init' now 'virgin'.
+        *
+        * @return      void
+        * @todo        We might want to move some calls to this method to fill it with life
         */
        public function nodeGeneratedSessionId () {
                // Create the new state instance
-               StateFactory::createStateInstanceByName('virgin', $this->getNodeInstance());
+               NodeStateFactory::createNodeStateInstanceByName('virgin');
        }
-
 }
 
 // [EOF]