PhpStorageInterface::save

public PhpStorageInterface::save($name, $code) Saves PHP code to storage. Parameters string $name: The virtual file name. Can be a relative path. string $code: The PHP code to be saved. Return value bool TRUE if the save succeeded, FALSE if it failed. File core/lib/Drupal/Component/PhpStorage/PhpStorageInterface.php, line 52 Class PhpStorageInterface Stores and loads PHP code. Namespace Drupal\Component\PhpStorage Code public function save($name, $code);

PhpStorageInterface::load

public PhpStorageInterface::load($name) Loads PHP code from storage. Depending on storage implementation, exists() checks can be expensive, so this function may be called for a file that doesn't exist, and that should not result in errors. This function does not return anything, so it is up to the caller to determine if any code was loaded (for example, check class_exists() or function_exists() for what was expected in the code). Parameters string $name: The virtual file name. Can be a relativ

PhpStorageInterface::listAll

public PhpStorageInterface::listAll() Lists all the files in the storage. Return value array Array of filenames. File core/lib/Drupal/Component/PhpStorage/PhpStorageInterface.php, line 95 Class PhpStorageInterface Stores and loads PHP code. Namespace Drupal\Component\PhpStorage Code public function listAll();

PhpStorageInterface::getFullPath

public PhpStorageInterface::getFullPath($name) Gets the full file path. Parameters string $name: The virtual file name. Can be a relative path. Return value string|false The full file path for the provided name. Return FALSE if the implementation needs to prevent access to the file. File core/lib/Drupal/Component/PhpStorage/PhpStorageInterface.php, line 87 Class PhpStorageInterface Stores and loads PHP code. Namespace Drupal\Component\PhpStorage Code public function getFullPath($name

PhpStorageInterface::garbageCollection

public PhpStorageInterface::garbageCollection() Performs garbage collection on the storage. The storage may choose to delete expired or invalidated items. File core/lib/Drupal/Component/PhpStorage/PhpStorageInterface.php, line 102 Class PhpStorageInterface Stores and loads PHP code. Namespace Drupal\Component\PhpStorage Code public function garbageCollection();

PhpStorageInterface::exists

public PhpStorageInterface::exists($name) Checks whether the PHP code exists in storage. Parameters string $name: The virtual file name. Can be a relative path. Return value bool TRUE if the virtual file exists, FALSE otherwise. File core/lib/Drupal/Component/PhpStorage/PhpStorageInterface.php, line 25 Class PhpStorageInterface Stores and loads PHP code. Namespace Drupal\Component\PhpStorage Code public function exists($name);

PhpStorageInterface::deleteAll

public PhpStorageInterface::deleteAll() Removes all files in this bin. File core/lib/Drupal/Component/PhpStorage/PhpStorageInterface.php, line 75 Class PhpStorageInterface Stores and loads PHP code. Namespace Drupal\Component\PhpStorage Code public function deleteAll();

PhpStorageInterface::delete

public PhpStorageInterface::delete($name) Deletes PHP code from storage. Parameters string $name: The virtual file name. Can be a relative path. Return value bool TRUE if the delete succeeded, FALSE if it failed. File core/lib/Drupal/Component/PhpStorage/PhpStorageInterface.php, line 70 Class PhpStorageInterface Stores and loads PHP code. Namespace Drupal\Component\PhpStorage Code public function delete($name);

PhpStorageInterface

Stores and loads PHP code. Each interface function takes $name as a parameter. This is a virtual file name: for example, 'foo.php' or 'some/relative/path/to/foo.php'. The storage implementation may store these as files within the local file system, use a remote stream, combine multiple virtual files into an archive, store them in database records, or use some other storage technique. Hierarchy interface \Drupal\Component\PhpStorage\PhpStorageInterface File core/lib/Drupal/Component/PhpStorag

PhpStorageFactory::get

static PhpStorageFactory::get($name) Instantiates a storage for generated PHP code. By default, this returns an instance of the \Drupal\Component\PhpStorage\MTimeProtectedFileStorage class. Classes implementing \Drupal\Component\PhpStorage\PhpStorageInterface can be registered for a specific bin or as a default implementation. Parameters string $name: The name for which the storage should be returned. Defaults to 'default' The name is also used as the storage bin if one is not specified in the