2 require_once(
'./Services/GlobalCache/classes/class.ilGlobalCache.php');
51 public function get() {
53 if ($ilGlobalCache->isActive()) {
54 $rec = $ilGlobalCache->get($this->cache_key);
56 $rec = $this->getFromDb();
57 $ilGlobalCache->set($this->cache_key, $rec, 600);
60 $rec = $this->getFromDb();
70 protected function getFromDb() {
76 $res = $ilDB->query($this->query);
78 case self::FETCH_TYPE_OBJECT:
79 while ($rec = $ilDB->fetchObject(
$res)) {
83 case self::FETCH_TYPE_ASSOC:
84 while ($rec = $ilDB->fetchAssoc(
$res)) {