You are here

public function FastPriorityQueue::contains in Zircon Profile 8.0

Same name and namespace in other branches
  1. 8 vendor/zendframework/zend-stdlib/src/FastPriorityQueue.php \Zend\Stdlib\FastPriorityQueue::contains()

Does the queue contain the given datum?

Parameters

mixed $datum:

Return value

bool

File

vendor/zendframework/zend-stdlib/src/FastPriorityQueue.php, line 323

Class

FastPriorityQueue
This is an efficient implementation of an integer priority queue in PHP

Namespace

Zend\Stdlib

Code

public function contains($datum) {
  foreach ($this->values as $values) {
    if (in_array($datum, $values)) {
      return true;
    }
  }
  return false;
}