public function contains($filename)
    {
        $this->initialize();

        try {
            $file = $this->matcher->getFile($filename);
        } catch (FileNotFoundException $e) {
            return false;
        }

        foreach ($this->files as $item) {
            if ($item->getFullPath() === $file->getFullPath()) {
                return true;
            }
        }

        return false;
    }
public function contains($filename)
    {
        $this->initialize();

        try {
            $file = $this->matcher->getFile($filename);
        } catch (FileNotFoundException $e) {
            return false;
        }

        foreach ($this->files as $item) {
            if ($item->getFullPath() === $file->getFullPath()) {
                return true;
            }
        }

        return false;
    }
public function contains ( $ filename ) { $ this -> initialize ( ) ; try { $ file = $ this -> matcher -> getFile ( $ filename ) ; } catch ( FileNotFoundException $ e ) { return false ; } foreach ( $ this -> files as $ item ) { if ( $ item -> getFullPath ( ) === $ file -> getFullPath ( ) ) { return true ; } } return false ; }
Check if a given file is present on the stack.

@param FileInterface|string $filename

@return bool
Check if a given file is present on the stack .