src/Serializer.php
public function deserializeFile($filename, $className = 'OpenApi\Annotations\OpenApi')
    {
        if (!$this->isValidClassName($className)) {
            throw new \Exception($className.' is not defined in OpenApi PHP Annotations');
        }
        $jsonString = file_get_contents($filename);
        return $this->doDeserialize(json_decode($jsonString), $className);
    }
public function deserializeFile($filename, $className = 'OpenApi\Annotations\OpenApi')
    {
        if (!$this->isValidClassName($className)) {
            throw new \Exception($className.' is not defined in OpenApi PHP Annotations');
        }
        $jsonString = file_get_contents($filename);
        return $this->doDeserialize(json_decode($jsonString), $className);
    }
public function deserializeFile ( $ filename , $ className = 'OpenApi\Annotations\OpenApi' ) { if ( ! $ this -> isValidClassName ( $ className ) ) { throw new \ Exception ( $ className . ' is not defined in OpenApi PHP Annotations' ) ; } $ jsonString = file_get_contents ( $ filename ) ; return $ this -> doDeserialize ( json_decode ( $ jsonString ) , $ className ) ; }
Deserialize a file

@param $filename
@param $className

@return Annotations\AbstractAnnotation

@throws \Exception
Deserialize a file