K2hKeyQueue::dump K2hKeyQueue Class K2hKeyQueue::pop

K2hKeyQueue::isEmpty

Returns whether the K2hKeyQueue is empty

Description

 public bool K2hKeyQueue::isEmpty ( void )

Returns where the K2hKeyQueue is empty.

Parameters

This function has no parameters.

Return Values

Returns true if the K2hKeyQueue object is empty, otherwise false.

Examples

<?php
$handle = k2hpx_open_mem();
$k2hkeyqueue = new K2hKeyQueue($handle, true, "test_queue_");
var_dump($k2hkeyqueue->count());
$k2hkeyqueue->push("test_queue_key", "test_queue_value");
var_dump($k2hkeyqueue->count());
var_dump($k2hkeyqueue->pop());
var_dump($k2hkeyqueue->count());
unset($k2hkeyqueue);
k2hpx_close($handle);
?>

The above example will output:

``` int(0) int(1) array(2) { [0]=> string(14) “test_queue_key” [1]=> string(16) “test_queue_value” } int(0) ``

K2hKeyQueue::dump K2hKeyQueue Class K2hKeyQueue::pop