You are here

interface FileInterface in Forena Reports 8

Hierarchy

Expanded class hierarchy of FileInterface

All classes that implement FileInterface

File

src/File/FileInterface.php, line 14

Namespace

Drupal\forena\File
View source
interface FileInterface {

  /**
   * @param $filename
   *   Name of file to check
   */
  public function isWritable($filename);

  /**
   * @param $filename
   *   Name of file to check for existence
   */
  public function exists($filename);

  /**
   * Determine if file is custom
   * @param $filename
   *   Name of file to load
   * @return Boolean
   *   True indicates there is no file to revert to.
   */
  public function isCustom($filename);

  /**
   * Determine if file is overriden
   * @param $filename
   * @return Boolean
   *   TRUE indicates that the file is different than
   *   module provided versions
   */
  public function isOverriden($filename);

  /**
   * @param $filename
   * @return mixed
   * Delete the contents of the file.
   * If the file has been overriden this only reverts the contents to the
   * original.
   */
  public function delete($filename);

  /**
   * Retrieve the contents of the file.
   */
  public function contents($filename);

  /**
   * Save the contents of a file.
   * @param $filename
   * @param $data
   * @return mixed
   */
  public function save($filename, $data);

  /**
   * Rerieve the meta data for a file.
   * Returns a structured object.
   * @param $filename
   * @return mixed
   */
  public function getMetaData($filename);

  /**
   * Loads metadata into object based on file type.
   * @param $object
   */
  public function extractMetaData(&$object);

}

Members

Namesort descending Modifiers Type Description Overrides
FileInterface::contents public function Retrieve the contents of the file. 1
FileInterface::delete public function 1
FileInterface::exists public function 1
FileInterface::extractMetaData public function Loads metadata into object based on file type. 2
FileInterface::getMetaData public function Rerieve the meta data for a file. Returns a structured object. 1
FileInterface::isCustom public function Determine if file is custom 1
FileInterface::isOverriden public function Determine if file is overriden 1
FileInterface::isWritable public function 1
FileInterface::save public function Save the contents of a file. 1