K2hash::getAttrInfos
Prints the attribute information
Description
public bool K2hash::getAttrInfos ([ mixed $output ] )
Prints the attribute information.
Parameters
- output
Specifies a file stream of data to be written.
Return Values
Returns true on success or false on failure.
Examples
- Example 1 - Prints the attributes information
<?php
$k2hash = new K2hash();
$k2hash->openMem();
$fp = fopen("/tmp/k2hash_attr_information.log", 'w');
$k2hash->getAttrInfos($fp);
fclose($fp);
$k2hash->close();
$fp = fopen("/tmp/k2hash_attr_information.log", 'r');
if ($fp) {
while (!feof($fp)) {
if (($buf = fgets($fp, 4096)) !== false) {
echo $buf;
}
}
fclose($fp);
}
?>
The above example will output:
K2HASH attribute libraries: K2H ATTR BUILTIN
See Also
- K2hash::addAttr - Adds the attribute to the key
- K2hash::addAttrCryptPass - Adds the password to encrypt values
- K2hash::addAttrPluginLib - Adds the user-defined library to handle attributes
- K2hash::cleanCommonAttribute - Initializes the common attributes
- K2hash::getAttrs - Gets attributes of the key
- K2hash::getAttrValue - Gets an attribute value of the attribute key of the key
- K2hash::getAttrVersionInfos - Prints the attribute library version