3 namespace Org\Mxchange\City\Daemon\Simulation;
5 // Import framework stuff
6 use Org\Mxchange\CoreFramework\Request\Requestable;
9 * A hub-node class for the '???' mode
11 * @author Roland Haeder <webmaster@ship-simu.org>
13 * @copyright Copyright (c) 2015, 2016 City Developer Team
14 * @license GNU GPL 3.0 or any newer version
15 * @link http://www.ship-simu.org
17 * This program is free software: you can redistribute it and/or modify
18 * it under the terms of the GNU General Public License as published by
19 * the Free Software Foundation, either version 3 of the License, or
20 * (at your option) any later version.
22 * This program is distributed in the hope that it will be useful,
23 * but WITHOUT ANY WARRANTY; without even the implied warranty of
24 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
25 * GNU General Public License for more details.
27 * You should have received a copy of the GNU General Public License
28 * along with this program. If not, see <http://www.gnu.org/licenses/>.
30 class Simulation???CityDaemon extends BaseCity implements CityHelper, Registerable {
32 * Protected constructor
36 protected function __construct () {
37 // Call parent constructor
38 parent::__construct(__CLASS__);
42 * Creates an instance of this hub-node class
44 * @param $requestInstance An instance of a Requestable class
45 * @return $nodeInstance An instance of this hub-node class
47 public final static function createSimulation???CityDaemon (Requestable $requestInstance) {
49 $nodeInstance = new Simulation???CityDaemon();
51 // Set the request instance
52 $nodeInstance->setRequestInstance($requestInstance);
54 // Return the instance
59 * Method to "bootstrap" the node. This step does also apply provided
60 * command-line arguments stored in the request instance. The regular node
61 * should communicate with the bootstrap-nodes at this point.
64 * @todo Implement this method
66 public function doBootstrapping () {
67 // Call generic (parent) bootstrapping method first
68 parent::doGenericBootstrapping();
69 $this->partialStub('Please implement this method.');
73 * Initializes hub-specific queues
76 * @todo Implement this method
78 public function initQueues () {
79 $this->partialStub('Please implement this method.');
83 * Add some node-specific filters
87 public function addExtraCityFilters () {
88 // Add some filters here
92 * Adds extra tasks to the given handler for this node
94 * @param $handlerInstance An instance of a HandleableTask class
98 public function addExtraTasks (HandleableTask $handlerInstance) {
99 $this->partialStub('Please add some tasks or empty this method.');