Cascade\Config\Loader\FileLoader\Yaml::supports PHP 메소드

supports() 공개 메소드

Return whether or not the resource passed in is supported by this loader !\ This does not validate Yaml content. The parser will raise an exception in that case
public supports ( string $resource, string $type = null ) : boolean
$resource string Plain string or filepath
$type string Not used
리턴 boolean Whether or not the passed in resrouce is supported by this loader
    public function supports($resource, $type = null)
    {
        if (!is_string($resource)) {
            return false;
        }
        if ($this->isFile($resource)) {
            return $this->validateExtension($resource);
        }
        return true;
    }