]> git.mxchange.org Git - shipsimu.git/blob - application/ship-simu/main/structures/extended/cabines/class_BaseCabin.php
interface added to setter
[shipsimu.git] / application / ship-simu / main / structures / extended / cabines / class_BaseCabin.php
1 <?php
2 // Kabinen allgemein
3 class BaseCabin extends BaseCabinStructure {
4         // Konstruktor
5         private function __construct ($class) {
6                 // Call parent constructor
7                 parent::constructor($class);
8
9                 //�Debug message
10                 if (((defined('DEBUG_CABIN')) || (defined('DEBUG_ALL'))) && (defined('DEBUG_CONSTRUCT'))) {
11                         $this->getDebugInstance()->output(sprintf("[%s:%d] Konstruktor erreicht.<br />\n",
12                                 __CLASS__,
13                                 __LINE__
14                         ));
15                 }
16
17                 // Set description
18                 $this->setPartDescr("Kabine");
19
20                 // Maybe clean up a little
21                 if ($class == __CLASS__) {
22                         $this->removeSystemArray();
23                 }
24         }
25
26         // Konstruktor aufrufen
27         public function constructor ($class) {
28                 $this->__construct($class);
29         }
30
31         // Allgemeine Kabine erstellen
32         public static function createBaseCabin () {
33                 // Instanz holen
34                 $cabinInstance = new BaseCabin(__CLASS__);
35
36                 // Debug message
37                 if ((defined('DEBUG_CABIN')) || (defined('DEBUG_ALL'))) $cabinInstance->getDebugInstance()->output(sprintf("[%s:%d] Eine allgemeine Kabine wird erstellt.<br />\n",
38                         __CLASS__,
39                         __LINE__
40                 ));
41
42                 // Generate unique ID number
43                 $cabinInstance->createUniqueID();
44
45                 // Instanz zurueckgeben
46                 return $cabinInstance;
47         }
48
49         // Is this a cabin?
50         public function isCabin () {
51                 return ($this->isClass("BaseCabin"));
52         }
53
54         /**
55          * Stub!
56          */
57         public function saveObjectToDatabase () {
58                 $this->getDebugInstance()->output(sprintf("[%s:] Stub <strong>%s</strong> erreicht.",
59                         $this->__toString(),
60                         __FUNCTION__
61                 ));
62         }
63
64         /**
65          * Limits this object with an ObjectLimits instance
66          */
67         public function limitObject (ObjectLimits $limitInstance) {
68                 ApplicationEntryPoint::app_die("".__METHOD__." reached! Stub!");
69         }
70 }
71
72 // [EOF]
73 ?>