N98\Util\Validator\FakeMetadataFactory::getMetadataFor PHP Method

getMetadataFor() public method

public getMetadataFor ( $class )
    public function getMetadataFor($class)
    {
        if (is_object($class)) {
            $class = get_class($class);
        }
        if (!is_string($class)) {
            throw new NoSuchMetadataException('No metadata for type ' . gettype($class));
        }
        if (!isset($this->metadatas[$class])) {
            throw new NoSuchMetadataException('No metadata for "' . $class . '"');
        }
        return $this->metadatas[$class];
    }