public function test_that_has_returns_true_for_valid_key() { $tree = new RedBlackSearchTree(new ComparableComparator()); foreach ($this->getWeekDays() as $value => $key) { $tree->set($key, $value); } $this->assertTrue($tree->has(WeekDay::SATURDAY())); }
/** * {@inheritdoc} */ public function contains($item) : bool { return $this->tree->has($item); }
/** * {@inheritdoc} */ public function has($key) : bool { return $this->tree->has($key); }