public function testRemoveAll() { $this->map->set('foo', 'bar', 'value1'); $this->map->set('foo', 'baz', 'value2'); $this->map->set('foo', 'bam', 'value3'); $this->map->set('bar', 'boo', 'value4'); $this->map->removeAll('foo'); $this->assertFalse($this->map->contains('foo')); $this->assertFalse($this->map->contains('foo', 'bar')); $this->assertFalse($this->map->contains('foo', 'baz')); $this->assertFalse($this->map->contains('foo', 'bam')); $this->setExpectedException('\\OutOfBoundsException'); $this->map->listByPrimaryKey('foo'); }
/** * Returns all type descriptors set for the given name. * * @param string $typeName The name of the type. * * @return BindingTypeDescriptor[] The type descriptors. * * @throws OutOfBoundsException If no type descriptor was set for the * given name. */ public function listByTypeName($typeName) { return $this->map->listByPrimaryKey($typeName); }
/** * Returns all path mappings set for the given repository path. * * @param string $repositoryPath The repository path of the mapping. * * @return PathMapping[] The path mappings. * * @throws OutOfBoundsException If no path mapping was set for the * given repository path. */ public function listByRepositoryPath($repositoryPath) { return $this->map->listByPrimaryKey($repositoryPath); }