Exemplo n.º 1
0
 public function testGetHash()
 {
     $this->assertEmpty($this->filterCollection->getHash());
     $this->filterCollection->addFilter('test', $this->filter);
     $this->filterCollection->enable('test');
     $this->assertEquals('testa:0:{}', $this->filterCollection->getHash());
     $this->filterCollection->disable('test');
     $this->assertEmpty($this->filterCollection->getHash());
 }
Exemplo n.º 2
0
 /**
  * Checks whether the Entity Manager has filters.
  *
  * @return boolean True, if the EM has a filter collection with enabled filters.
  */
 public function hasFilters()
 {
     return null !== $this->filterCollection && $this->filterCollection->getEnabledFilters();
 }