StructureDecoder implements ValueDecoder
FinalYes
Interfaces
Methods
- __construct() : mixed
- decode() : array<string|int, mixed>
Methods
__construct()
public
__construct(array<string|int, ValueDecoder> $elements, bool $allowsExtra, DynamicDecoder $dynamic) : mixed
Parameters
- $elements : array<string|int, ValueDecoder>
-
structure element name => decoder
- $allowsExtra : bool
- $dynamic : DynamicDecoder
decode()
public
decode(string $data, int &$position) : array<string|int, mixed>
Parameters
- $data : string
- $position : int
-
read position, advanced past the consumed bytes