@@ 533-540 (lines=8) @@ | ||
530 | } |
|
531 | ||
532 | /** Cache controller is used to attempt and load data a little faster then the primary controller */ |
|
533 | public function addCache($controller, $table = null, $priority = 5) |
|
534 | { |
|
535 | $controller = $this->app->normalizeClassName($controller, 'Data'); |
|
536 | ||
537 | return $this->setController($controller) |
|
538 | ->addHooks($this, $priority) |
|
539 | ->setSource($this, $table); |
|
540 | } |
|
541 | ||
542 | /** Returns if certain feature is supported by model */ |
|
543 | public function supports($feature) |
@@ 1343-1350 (lines=8) @@ | ||
1340 | /** |
|
1341 | * @todo This is something wierd. Method addHooks is not defined anywhere in ATK source |
|
1342 | */ |
|
1343 | public function addCache($controller, $table = null, $priority = 5) |
|
1344 | { |
|
1345 | $controller = $this->app->normalizeClassName($controller, 'Data'); |
|
1346 | ||
1347 | return $this->setController($controller) |
|
1348 | ->addHooks($this, $priority) |
|
1349 | ->setSource($this, $table); |
|
1350 | } |
|
1351 | ||
1352 | public function each($callable) |
|
1353 | { |