PHP Class App\Services\Repositories\Repository

Inheritance: implements ArrayAcces\ArrayAccess
Datei anzeigen Open project: printempw/blessing-skin-server

Protected Properties

Property Type Description
$items array All of the items.
$itemsModified array All of the option items that is modified.

Public Methods

Method Description
all ( ) : array Get all of the items stored in the repository.
forget ( string $key ) : boolean Remove an item from the repository.
get ( string $key, mixed $default = null ) : mixed Retrieve an item from the repository by key.
has ( string $key ) : boolean Determine if an item exists in the repository.
offsetExists ( string $key ) : boolean Determine if the given option option exists.
offsetGet ( string $key ) : mixed Get a option option.
offsetSet ( string $key, mixed $value ) : void Set a option option.
offsetUnset ( string $key ) : void Unset a option option.
push ( mixed $item ) : void Push an item into the repository.
remember ( string $key, Closure $callback ) : mixed Get an item from the repository, or store the default value.
set ( array | string $key, mixed $value = null ) : void Set a given option value.

Method Details

all() public method

Get all of the items stored in the repository.
public all ( ) : array
return array

forget() public method

Remove an item from the repository.
public forget ( string $key ) : boolean
$key string
return boolean

get() public method

Retrieve an item from the repository by key.
public get ( string $key, mixed $default = null ) : mixed
$key string
$default mixed
return mixed

has() public method

Determine if an item exists in the repository.
public has ( string $key ) : boolean
$key string
return boolean

offsetExists() public method

Determine if the given option option exists.
public offsetExists ( string $key ) : boolean
$key string
return boolean

offsetGet() public method

Get a option option.
public offsetGet ( string $key ) : mixed
$key string
return mixed

offsetSet() public method

Set a option option.
public offsetSet ( string $key, mixed $value ) : void
$key string
$value mixed
return void

offsetUnset() public method

Unset a option option.
public offsetUnset ( string $key ) : void
$key string
return void

push() public method

Push an item into the repository.
public push ( mixed $item ) : void
$item mixed
return void

remember() public method

Get an item from the repository, or store the default value.
public remember ( string $key, Closure $callback ) : mixed
$key string
$callback Closure
return mixed

set() public method

Set a given option value.
public set ( array | string $key, mixed $value = null ) : void
$key array | string
$value mixed
return void

Property Details

$items protected_oe property

All of the items.
protected array $items
return array

$itemsModified protected_oe property

All of the option items that is modified.
protected array $itemsModified
return array