32 lines
546 B
PHP
32 lines
546 B
PHP
<?php
|
|
|
|
|
|
// *****************************************
|
|
// * Singleton Class für global parameters *
|
|
// *****************************************
|
|
|
|
class GDC {
|
|
|
|
private static $inst = null;
|
|
private $gdc = array();
|
|
|
|
private function __construct() { }
|
|
|
|
public static function getInstance() {
|
|
if (self::$inst === null) {
|
|
self::$inst = new self();
|
|
}
|
|
return self::$inst;
|
|
}
|
|
|
|
public function setVal($key, $val) {
|
|
$this->gdc[$key] = $val;
|
|
}
|
|
|
|
public function getVal($key) {
|
|
return $this->gdc[$key];
|
|
}
|
|
}
|
|
|
|
?>
|