Stores information about map tags on page in ParserOutput.
More...
|
static | getState (ParserOutput $output) |
| Retrieves an instance of self from ParserOutput, if present.
|
|
static | getOrCreate (ParserOutput $output) |
| Retrieves an instance of self from ParserOutput if possible, otherwise creates a new instance.
|
|
static | saveState (ContentMetadataCollector $output, self $state) |
| Stores an instance of self in the ParserOutput.
|
|
|
const | DATA_KEY = 'kartographer' |
|
Stores information about map tags on page in ParserOutput.
@license MIT
◆ addData()
Kartographer\State::addData |
( |
| $groupId, |
|
|
array | $data ) |
- Parameters
-
string | $groupId | |
array | $data | A JSON-serializable structure |
◆ addInteractiveGroups()
Kartographer\State::addInteractiveGroups |
( |
array | $groupIds | ) |
|
◆ addRequestedGroups()
Kartographer\State::addRequestedGroups |
( |
array | $groupIds | ) |
|
◆ getCounters()
Kartographer\State::getCounters |
( |
| ) |
|
◆ getData()
Kartographer\State::getData |
( |
| ) |
|
- Returns
- array<string,array> Associative key-value array, build up by {
- See also
- addData}
◆ getInteractiveGroups()
Kartographer\State::getInteractiveGroups |
( |
| ) |
|
- Returns
- string[] Group ids, guaranteed to be unique
◆ getOrCreate()
static Kartographer\State::getOrCreate |
( |
ParserOutput | $output | ) |
|
|
static |
Retrieves an instance of self from ParserOutput if possible, otherwise creates a new instance.
- Parameters
-
- Returns
- self
◆ getRequestedGroups()
Kartographer\State::getRequestedGroups |
( |
| ) |
|
- Returns
- string[] Group ids, guaranteed to be unique
◆ getState()
static Kartographer\State::getState |
( |
ParserOutput | $output | ) |
|
|
static |
Retrieves an instance of self from ParserOutput, if present.
- Parameters
-
- Returns
- self|null
◆ getUsages()
Kartographer\State::getUsages |
( |
| ) |
|
◆ jsonSerialize()
Kartographer\State::jsonSerialize |
( |
| ) |
|
- Returns
- array A JSON serializable associative array
◆ saveState()
static Kartographer\State::saveState |
( |
ContentMetadataCollector | $output, |
|
|
self | $state ) |
|
static |
Stores an instance of self in the ParserOutput.
- Parameters
-
ContentMetadataCollector | $output | |
self | $state | |
◆ setCounters()
Kartographer\State::setCounters |
( |
array | $counters | ) |
|
- Parameters
-
array<string,int> | $counters A JSON-serializable structure |
The documentation for this class was generated from the following file: