From 70beccc6b8f9698dd2fd42bfbdc8f71b18fc0a30 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Sun, 11 Sep 2011 09:28:26 +0000 Subject: [PATCH] Some 'abstract' are required --- .gitattributes | 1 + .../main/chat/console/class_NodeConsoleChat.php | 13 ++++++++++++- .../states/peer/class_PeerStateFactory.php | 10 +++++----- .../hub/main/producer/class_BaseProducer.php | 2 +- .../producer/cruncher/class_BaseKeyProducer.php | 2 +- .../producer/cruncher/class_BaseUnitProducer.php | 2 +- docs/AUTHORS.txt | 15 +++++++++++++++ index.php | 2 -- 8 files changed, 36 insertions(+), 11 deletions(-) create mode 100644 docs/AUTHORS.txt diff --git a/.gitattributes b/.gitattributes index 544de4bea..2ccd8ddc2 100644 --- a/.gitattributes +++ b/.gitattributes @@ -572,6 +572,7 @@ db/node_data/.htaccess -text svneol=unset#text/plain db/node_list/.htaccess -text svneol=unset#text/plain db/node_states/.htaccess -text svneol=unset#text/plain db/peer_states/.htaccess -text svneol=unset#text/plain +docs/AUTHORS.txt svneol=native#text/plain docs/COPYING -text docs/COPYING.documents -text docs/COPYING.software -text diff --git a/application/hub/main/chat/console/class_NodeConsoleChat.php b/application/hub/main/chat/console/class_NodeConsoleChat.php index 46bb5b742..1a346ceea 100644 --- a/application/hub/main/chat/console/class_NodeConsoleChat.php +++ b/application/hub/main/chat/console/class_NodeConsoleChat.php @@ -63,7 +63,18 @@ class NodeConsoleChat extends BaseNodeChat implements Chatter, Registerable { * @return void */ public function outputConsoleTeaser () { - $this->partialStub('Please implement this method.'); + // Get the app instance (for shortening our code) + $app = $this->getApplicationInstance(); + + // Output all lines + $this->debugOutput(' '); + $this->debugOutput($app->getAppName() . ' v' . $app->getAppVersion() . ' - A telnet connection helper'); + $this->debugOutput('Copyright (c) 2007 - 2008 Roland Haeder, 2009 - 2011 Hub Developer Team'); + $this->debugOutput(' '); + $this->debugOutput('This program comes with ABSOLUTELY NO WARRANTY; for details see docs/COPYING.'); + $this->debugOutput('This is free software, and you are welcome to redistribute it under certain'); + $this->debugOutput('conditions; see docs/COPYING for details.'); + $this->debugOutput(' '); } /** diff --git a/application/hub/main/factories/states/peer/class_PeerStateFactory.php b/application/hub/main/factories/states/peer/class_PeerStateFactory.php index 181fc9700..2837ae665 100644 --- a/application/hub/main/factories/states/peer/class_PeerStateFactory.php +++ b/application/hub/main/factories/states/peer/class_PeerStateFactory.php @@ -82,14 +82,14 @@ class PeerStateFactory extends ObjectFactory { // Debug output $tableInstance->debugOutput('PEER-STATE-FACTORY: errorCode=' . $errorCode); - // Is a new peer so create the state instance based on error code, first we need a config entry - $configEntry = 'peer_' . $errorCode . '_state_class'; - // Register the new peer with its session id $tableInstance->registerPeerByPackageData($packageData, $socketResource); - // Then get it - $stateInstance = self::createObjectByConfiguredName($configEntry); + /* + * It is a new peer so create the state instance based on error + * code and get an instance from it. + */ + $stateInstance = self::createObjectByConfiguredName('peer_' . $errorCode . '_state_class'); // And register it with the lookup table $tableInstance->registerPeerState($stateInstance, $packageData); diff --git a/application/hub/main/producer/class_BaseProducer.php b/application/hub/main/producer/class_BaseProducer.php index ee5976cbf..e69b83f7f 100644 --- a/application/hub/main/producer/class_BaseProducer.php +++ b/application/hub/main/producer/class_BaseProducer.php @@ -21,7 +21,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ -class BaseProducer extends BaseFrameworkSystem { +abstract class BaseProducer extends BaseFrameworkSystem { /** * Outgoing work-queue */ diff --git a/application/hub/main/producer/cruncher/class_BaseKeyProducer.php b/application/hub/main/producer/cruncher/class_BaseKeyProducer.php index 599412aa6..c89fa5778 100644 --- a/application/hub/main/producer/cruncher/class_BaseKeyProducer.php +++ b/application/hub/main/producer/cruncher/class_BaseKeyProducer.php @@ -21,7 +21,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ -class BaseKeyProducer extends BaseProducer { +abstract class BaseKeyProducer extends BaseProducer { /** * Protected constructor * diff --git a/application/hub/main/producer/cruncher/class_BaseUnitProducer.php b/application/hub/main/producer/cruncher/class_BaseUnitProducer.php index 46ffd6f11..6c1c4bc20 100644 --- a/application/hub/main/producer/cruncher/class_BaseUnitProducer.php +++ b/application/hub/main/producer/cruncher/class_BaseUnitProducer.php @@ -21,7 +21,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ -class BaseUnitProducer extends BaseProducer { +abstract class BaseUnitProducer extends BaseProducer { /** * Work/test unit status */ diff --git a/docs/AUTHORS.txt b/docs/AUTHORS.txt new file mode 100644 index 000000000..4d83d708b --- /dev/null +++ b/docs/AUTHORS.txt @@ -0,0 +1,15 @@ +[--------------------------------------] +[-- All main authors of this script: --] +[--------------------------------------] + +- Roland Haeder + + (project leader, webmaster, main programmer) + +[----------------------------------------] +[-- Contributors (code, designs, etc.) --] +[----------------------------------------] + +- Mr. X + + (requested to be listed... ;-) ) diff --git a/index.php b/index.php index c0af3b26d..fea50278e 100644 --- a/index.php +++ b/index.php @@ -34,8 +34,6 @@ final class ApplicationEntryPoint { /** * The instances we want to remove after all is done - * - * @return void */ private static $instances = array ( 'cfg', // The configuration system -- 2.39.5