Judy Arrays
- Введение
- Установка и настройка
- Judy — The Judy class
- Judy::byCount — Locate the Nth index present in the Judy array
- Judy::__construct — Construct a new Judy object
- Judy::count — Count the number of elements in the Judy array
- Judy::__destruct — Destruct a Judy object
- Judy::first — Search for the first index in the Judy array
- Judy::firstEmpty — Search for the first absent index in the Judy array
- Judy::free — Free the entire Judy array
- Judy::getType — Return the type of the current Judy array
- Judy::last — Search for the last index in the Judy array
- Judy::lastEmpty — Search for the last absent index in the Judy array
- Judy::memoryUsage — Return the memory used by the Judy array
- Judy::next — Search for the next index in the Judy array
- Judy::nextEmpty — Search for the next absent index in the Judy array
- Judy::offsetExists — Whether a offset exists
- Judy::offsetGet — Offset to retrieve
- Judy::offsetSet — Offset to set
- Judy::offsetUnset — Offset to unset
- Judy::prev — Search for the previous index in the Judy array
- Judy::prevEmpty — Search for the previous absent index in the Judy array
- Judy::size — Return the size of the current Judy array
- Judy Функции
- judy_type — Return the type of a Judy array
- judy_version — Return or print the current PHP Judy version
Коментарии
Iterating through a Judy array with key as string and values of any type:
<?php
$judy = new Judy(Judy::STRING_TO_MIXED);
$judy["foo"] = "bar";
$judy["veggie"] = "carrot";
$judy["taste"] = "sweet";
if($judy->count() > 0) {
$key = $judy->first();
do {
var_dump($judy[$key]);
}while (!is_null($key = $judy->next($key))) ;
}
?>