You are here

class RealisticDummyContentLiveEnvironment in Realistic Dummy Content 7

The live environment.

During normal execution, we want to do things like interact with the file- system and such. However during testing we want to abstract that away. This class represents the live environment.

Hierarchy

Expanded class hierarchy of RealisticDummyContentLiveEnvironment

File

api/includes/RealisticDummyContentLiveEnvironment.inc, line 16
Define RealisticDummyContentLiveEnvironment autoload class.

View source
class RealisticDummyContentLiveEnvironment extends RealisticDummyContentEnvironment {

  /**
   * {@inheritdoc}
   */
  function _file_get_contents_($filename) {
    return file_get_contents($filename);
  }
  function _file_save_data_($data, $destination = NULL) {
    return file_save_data($data, $destination);
  }
  function _file_save_(stdClass $file) {
    return file_save($file);
  }

}

Members

Namesort descending Modifiers Type Description Overrides
RealisticDummyContentEnvironment::$env private static property
RealisticDummyContentEnvironment::addFileToArray static function
RealisticDummyContentEnvironment::AttributeName static function Returns the attribute of a filename if one exists
RealisticDummyContentEnvironment::FilenameRadical static function Returns the name radical of a filename.
RealisticDummyContentEnvironment::file_get_contents function Get the contents of a file.
RealisticDummyContentEnvironment::file_save function
RealisticDummyContentEnvironment::file_save_data function Save the file data to the real or test environment.
RealisticDummyContentEnvironment::Get static function Get the current environment.
RealisticDummyContentEnvironment::GetAllFileGroups static function Returns all files with a given extension for a given filepath.
RealisticDummyContentEnvironment::GetFileContents static function Returns the trimmed contents of a Drpual file object, or NULL if empty.
RealisticDummyContentEnvironment::getFileParts static function
RealisticDummyContentEnvironment::LowercaseRadicalNoExtension static function Returns the part of a string before the extension, in lowercase
RealisticDummyContentEnvironment::Replace static function Returns part of a filename
RealisticDummyContentEnvironment::Set static function Set the current environment
RealisticDummyContentEnvironment::SortCandidateFiles static function Given a list of candidate files, sort them by names and parts.
RealisticDummyContentEnvironment::SortCandidateFiles_ static function Given a list of candidate files, sort them by names and parts.
RealisticDummyContentEnvironment::validCandidateFilename static function
RealisticDummyContentLiveEnvironment::_file_get_contents_ function Internal function used to get the contents of a file. Overrides RealisticDummyContentEnvironment::_file_get_contents_
RealisticDummyContentLiveEnvironment::_file_save_ function Overrides RealisticDummyContentEnvironment::_file_save_
RealisticDummyContentLiveEnvironment::_file_save_data_ function Overrides RealisticDummyContentEnvironment::_file_save_data_