| 12345678910111213141516171819202122232425262728293031 |
- <?php
- /**
- * SE/schema/ant-object/default_db.{lower(rootTableName)}/{name}/build.xml
- */
- class AntAclBase extends Core_AclBase {
- public $_zasobID = '';
- public function __construct($zasobID = 0) {
- $this->_zasobID = $zasobID;
- }
- public function getName() { return $this->_name; }
- public function getNamespace() { return 'default_db/' . $this->getName(); }
- public function getSourceName() { return 'default_db'; }
- public function getRootTableName() { throw new Exception("TODO: " . get_class($this) . "::F." . __FUNCTION__); }
- public static function buildInstance($idZasob, $conf = []) {
- static $_cache;
- if (!$_cache) $_cache = array();
- if (array_key_exists($idZasob, $_cache)) {
- return $_cache[$idZasob];
- }
- if (empty($conf)) throw new Exception("Brak danych konfiguracyjnych do obiektu ant nr {$idZasob}");
- DBG::nicePrint($conf, 'AntAclBase::buildInstance $conf');
- $_cache[$idZasob] = new AntAclBase($idZasob);
- return $_cache[$idZasob];
- }
- }
|