public function getMetadataFor($value)
    {
        $metaData = new ClassMetadata(get_class($value));
        $fullClass = $this->getClassValidator($value);

        if (empty($fullClass)) {
            return $metaData;
        }

        /** @var $loader LoaderMetadataInterface */
        $loader = new $fullClass();
        $loader->load($metaData);
        if ($this->listener) {
            $this->listener->onLoaded($value, $metaData);
        }

        return $metaData;
    }
public function getMetadataFor($value)
    {
        $metaData = new ClassMetadata(get_class($value));
        $fullClass = $this->getClassValidator($value);

        if (empty($fullClass)) {
            return $metaData;
        }

        /** @var $loader LoaderMetadataInterface */
        $loader = new $fullClass();
        $loader->load($metaData);
        if ($this->listener) {
            $this->listener->onLoaded($value, $metaData);
        }

        return $metaData;
    }
public function getMetadataFor ( $ value ) { $ metaData = new ClassMetadata ( get_class ( $ value ) ) ; $ fullClass = $ this -> getClassValidator ( $ value ) ; if ( empty ( $ fullClass ) ) { return $ metaData ; } /** @var $loader LoaderMetadataInterface */ $ loader = new $ fullClass ( ) ; $ loader -> load ( $ metaData ) ; if ( $ this -> listener ) { $ this -> listener -> onLoaded ( $ value , $ metaData ) ; } return $ metaData ; }
Returns the metadata for the given value.

@param mixed $value Some value

@return MetadataInterface The metadata for the value

@throws NoSuchMetadataException If no metadata exists for the given value
Returns the metadata for the given value .