public function getMapping($namespace)
    {
        $cacheName = 'ongr.metadata.document.'.md5($namespace);

        $namespace = $this->getClassName($namespace);
        $this->enableCache && $mapping = $this->cache->fetch($cacheName);

        if (isset($mapping) && false !== $mapping) {
            return $mapping;
        }

        $mapping = $this->getDocumentReflectionMapping(new \ReflectionClass($namespace));

        $this->enableCache && $this->cache->save($cacheName, $mapping);

        return $mapping;
    }
public function getMapping($namespace)
    {
        $cacheName = 'ongr.metadata.document.'.md5($namespace);

        $namespace = $this->getClassName($namespace);
        $this->enableCache && $mapping = $this->cache->fetch($cacheName);

        if (isset($mapping) && false !== $mapping) {
            return $mapping;
        }

        $mapping = $this->getDocumentReflectionMapping(new \ReflectionClass($namespace));

        $this->enableCache && $this->cache->save($cacheName, $mapping);

        return $mapping;
    }
public function getMapping ( $ namespace ) { $ cacheName = 'ongr.metadata.document.' . md5 ( $ namespace ) ; $ namespace = $ this -> getClassName ( $ namespace ) ; $ this -> enableCache && $ mapping = $ this -> cache -> fetch ( $ cacheName ) ; if ( isset ( $ mapping ) && false !== $ mapping ) { return $ mapping ; } $ mapping = $ this -> getDocumentReflectionMapping ( new \ ReflectionClass ( $ namespace ) ) ; $ this -> enableCache && $ this -> cache -> save ( $ cacheName , $ mapping ) ; return $ mapping ; }
Returns single document mapping metadata.

@param string $namespace Document namespace

@return array
@throws DocumentParserException
Returns single document mapping metadata .