ILIAS  release_5-1 Revision 5.0.0-5477-g43f3e3fab5f
StringHash.php
Go to the documentation of this file.
1<?php
2
12{
16 protected $accessed = array();
17
23 public function offsetGet($index)
24 {
25 $this->accessed[$index] = true;
26 return parent::offsetGet($index);
27 }
28
33 public function getAccessed()
34 {
35 return $this->accessed;
36 }
37
41 public function resetAccessed()
42 {
43 $this->accessed = array();
44 }
45}
46
47// vim: et sw=4 sts=4
This is in almost every respect equivalent to an array except that it keeps track of which keys were ...
Definition: StringHash.php:12
offsetGet($index)
Retrieves a value, and logs the access.
Definition: StringHash.php:23
getAccessed()
Returns a lookup array of all array indexes that have been accessed.
Definition: StringHash.php:33
resetAccessed()
Resets the access array.
Definition: StringHash.php:41