ArrayAccessGetterSetter
in package
implements
PropagationGetterInterface, PropagationSetterInterface
FinalYes
Tags
Table of Contents
Interfaces
Properties
- $instance : self|null
Methods
- get() : string|null
- Gets the value of a given key from a carrier.
- getInstance() : self
- Returns a singleton instance of `self` to avoid, multiple runtime allocations.
- keys() : array<int, string>
- Returns the list of all the keys in the carrier.
- set() : void
- Set the value for a given key on the associated carrier.
- isSupportedCarrier() : bool
- resolveKey() : string
Properties
$instance
private
static self|null
$instance
= null
Methods
get()
Gets the value of a given key from a carrier.
public
get(mixed $carrier, string $key) : string|null
Parameters
- $carrier : mixed
- $key : string
Return values
string|nullgetInstance()
Returns a singleton instance of `self` to avoid, multiple runtime allocations.
public
static getInstance() : self
Return values
selfkeys()
Returns the list of all the keys in the carrier.
public
keys(mixed $carrier) : array<int, string>
Parameters
- $carrier : mixed
Return values
array<int, string>set()
Set the value for a given key on the associated carrier.
public
set(mixed &$carrier, string $key, string $value) : void
Parameters
- $carrier : mixed
- $key : string
- $value : string
isSupportedCarrier()
private
isSupportedCarrier(mixed $carrier) : bool
Parameters
- $carrier : mixed
Return values
boolresolveKey()
private
resolveKey(mixed $carrier, string $key) : string
Parameters
- $carrier : mixed
- $key : string