示例#1
0
 /**
  * Can this file be modified by this modifier
  *
  * @param FileNodeInterface $file
  *
  * @return bool
  */
 public function canModify(FileNodeInterface $file)
 {
     return $file->exists() && $file instanceof FormatAwareInterface && $file->getFormat() !== null && $this->parserFactory->getParser($file->getFormat()) !== null;
 }
示例#2
0
文件: Head.php 项目: graze/data-file
 /**
  * Can this file be modified by this modifier
  *
  * @param FileNodeInterface $file
  *
  * @return bool
  */
 public function canModify(FileNodeInterface $file)
 {
     return $file instanceof LocalFile && $file->exists();
 }