Horde_Data_Storage_Mock implements Horde_Data_Storage
A mocked version of the storage class that stores data for the current page access only.
Tags
Interfaces, Classes and Traits
- Horde_Data_Storage
- Abstract class that implements the temporary storage backend.
Table of Contents
- $_data : array<string|int, mixed>
- Data storage.
- clear() : mixed
- Clear all stored data.
- exists() : bool
- Does the key exist?
- get() : mixed
- Retrieve the data for a key.
- set() : mixed
- Set the data for a key.
Properties
$_data
Data storage.
protected
array<string|int, mixed>
$_data
= array()
Methods
clear()
Clear all stored data.
public
clear() : mixed
Return values
mixed —exists()
Does the key exist?
public
exists(mixed $key) : bool
Parameters
- $key : mixed
-
Key.
Return values
bool —Does the key exist?
get()
Retrieve the data for a key.
public
get(mixed $key) : mixed
Parameters
- $key : mixed
-
Key.
Return values
mixed —Data value.
set()
Set the data for a key.
public
set(mixed $key[, mixed $value = null ]) : mixed
Parameters
- $key : mixed
-
Key.
- $value : mixed = null
-
Value. If null, clears the key value.