ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
League\Flysystem\SafeStorage Class Reference
+ Collaboration diagram for League\Flysystem\SafeStorage:

Public Member Functions

 __construct ()
 
 storeSafely ($key, $value)
 
 retrieveSafely ($key)
 
 __destruct ()
 

Static Protected Attributes

static $safeStorage = []
 

Private Attributes

 $hash
 

Detailed Description

Definition at line 5 of file SafeStorage.php.

Constructor & Destructor Documentation

◆ __construct()

League\Flysystem\SafeStorage::__construct ( )

Definition at line 17 of file SafeStorage.php.

18 {
19 $this->hash = spl_object_hash($this);
20 static::$safeStorage[$this->hash] = [];
21 }
hash(StreamInterface $stream, $algo, $rawOutput=false)
Calculate a hash of a Stream.
Definition: functions.php:406

References League\Flysystem\SafeStorage\$hash, and GuzzleHttp\Psr7\hash().

+ Here is the call graph for this function:

◆ __destruct()

League\Flysystem\SafeStorage::__destruct ( )

Definition at line 35 of file SafeStorage.php.

36 {
37 unset(static::$safeStorage[$this->hash]);
38 }

References GuzzleHttp\Psr7\hash().

+ Here is the call graph for this function:

Member Function Documentation

◆ retrieveSafely()

League\Flysystem\SafeStorage::retrieveSafely (   $key)

Definition at line 28 of file SafeStorage.php.

29 {
30 if (array_key_exists($key, static::$safeStorage[$this->hash])) {
31 return static::$safeStorage[$this->hash][$key];
32 }
33 }
$key
Definition: croninfo.php:18

References League\Flysystem\SafeStorage\$hash, $key, and GuzzleHttp\Psr7\hash().

+ Here is the call graph for this function:

◆ storeSafely()

League\Flysystem\SafeStorage::storeSafely (   $key,
  $value 
)

Definition at line 23 of file SafeStorage.php.

24 {
25 static::$safeStorage[$this->hash][$key] = $value;
26 }

References League\Flysystem\SafeStorage\$hash, and $key.

Field Documentation

◆ $hash

League\Flysystem\SafeStorage::$hash
private

◆ $safeStorage

League\Flysystem\SafeStorage::$safeStorage = []
staticprotected

Definition at line 15 of file SafeStorage.php.


The documentation for this class was generated from the following file: