6 protected static $pool = array();
11 if (isset(static::$pool[$code]))
13 return static::$pool[$code];
19 public static function get($code, $type)
21 if (isset(static::$pool[$code][$type]))
23 return static::$pool[$code][$type];
38 if (isset(static::$pool[$code][$type][
$index]))
40 return static::$pool[$code][$type][
$index];
51 public static function add($code, $type, $value)
54 static::$pool[$code][$type][static::$index] = $value;
62 public static function delete($code, $type,
$index)
64 if (isset(static::$pool[$code][$type][
$index]))
66 unset(static::$pool[$code][$type][
$index]);
78 return (!empty(static::$pool[$code][$type]));
85 public static function resetPool($code =
null, $type =
null)
91 unset(static::$pool[$code][$type]);
95 unset(static::$pool[$code]);
100 static::$pool = array();
103 if (empty(static::$pool[$code]))
105 unset(static::$pool[$code]);
static resetPool($code=null, $type=null)
static add($code, $type, $value)
static getPoolByCode($code)
static isTypeExists($code, $type)
static getByIndex($code, $type, $index)