DataInterface
in
Interface DataInterface
Table of Contents
Methods
- blueprints() : Blueprint
- Return blueprints.
- extra() : array<string|int, mixed>
- Get extra items which haven't been defined in blueprints.
- file() : FileInterface
- Set or get the data storage.
- filter() : $this
- Filter all items by using blueprints.
- merge() : mixed
- Merge external data.
- save() : void
- Save data into the file.
- validate() : $this
- Validate by blueprints.
- value() : mixed
- Get value by using dot notation for nested arrays/objects.
Methods
blueprints()
Return blueprints.
public
blueprints() : Blueprint
Return values
Blueprintextra()
Get extra items which haven't been defined in blueprints.
public
extra() : array<string|int, mixed>
Return values
array<string|int, mixed>file()
Set or get the data storage.
public
file([FileInterface|null $storage = null ]) : FileInterface
Parameters
- $storage : FileInterface|null = null
-
Optionally enter a new storage.
Return values
FileInterfacefilter()
Filter all items by using blueprints.
public
filter() : $this
Return values
$thismerge()
Merge external data.
public
merge(array<string|int, mixed> $data) : mixed
Parameters
- $data : array<string|int, mixed>
save()
Save data into the file.
public
save() : void
validate()
Validate by blueprints.
public
validate() : $this
Tags
Return values
$thisvalue()
Get value by using dot notation for nested arrays/objects.
public
value(string $name[, mixed $default = null ][, string $separator = '.' ]) : mixed
Parameters
- $name : string
-
Dot separated path to the requested value.
- $default : mixed = null
-
Default value (or null).
- $separator : string = '.'
-
Separator, defaults to '.'
Tags
Return values
mixed —Value.