public function writeTo($path)
    {
        try {
            $resource = $this->getImageResource();
            if (!$resource) {
                throw new BadMethodCallException("Cannot write corrupt file to store");
            }
            $resource->save($path, $this->getQuality());
        } catch (NotWritableException $e) {
            return false;
        }
        return true;
    }
public function writeTo($path)
    {
        try {
            $resource = $this->getImageResource();
            if (!$resource) {
                throw new BadMethodCallException("Cannot write corrupt file to store");
            }
            $resource->save($path, $this->getQuality());
        } catch (NotWritableException $e) {
            return false;
        }
        return true;
    }
public function writeTo ( $ path ) { try { $ resource = $ this -> getImageResource ( ) ; if ( ! $ resource ) { throw new BadMethodCallException ( "Cannot write corrupt file to store" ) ; } $ resource -> save ( $ path , $ this -> getQuality ( ) ) ; } catch ( NotWritableException $ e ) { return false ; } return true ; }
Write the backend to a local path

@param string $path
@return bool If the writing was successful
@throws BadMethodCallException If image isn't valid
Write the backend to a local path