K2hash::getStream K2hash Class K2hash::getTransactionThreadPool

K2hash::getSubkeys

Gets an array of keys associated with the key

Description

public arrayfalseK2hash::getSubkeys ( string $key [, bool $attrcheck ] )

Gets an array of the keys associated with the key.

Parameters

Return Values

Returns an array of keys associated with the key.

Examples

<?php
$k2hash = new K2hash();
$k2hash->openMem();
$k2hash->addSubkeys("test", array("subkey1", "subkey2", "subkey3"));
var_dump($k2hash->getSubkeys("test"));
$k2hash->close();
?>

The above example will output:

array(3) {
  [0]=>
  string(7) "subkey1"
  [1]=>
  string(7) "subkey2"
  [2]=>
  string(7) "subkey3"
}

See Also

K2hash::getStream K2hash Class K2hash::getTransactionThreadPool