Wikibase
MediaWiki Wikibase extension
|
Value object representing the entity usages on a single page. More...
Public Member Functions | |
__construct ( $pageId, array $usages=[]) | |
getPageId () | |
Returns the page this PageEntityUsages object applies to. More... | |
getUsages () | |
isEmpty () | |
addUsages (array $usages) | |
getAspects () | |
Collects all usage aspects present on the page. More... | |
getAspectKeys () | |
Collects all usage aspects present on the page. More... | |
equals (self $other) | |
getEntityIds () | |
Returns all entities used on the page represented by this PageEntityUsages object. More... | |
getUsageAspectKeys (EntityId $id) | |
Returns the aspects used by the given entity on the page represented by this PageEntityUsages object. More... | |
__toString () | |
Private Attributes | |
$pageId | |
$usages = [] | |
Value object representing the entity usages on a single page.
Wikibase\Client\Usage\PageEntityUsages::__construct | ( | $pageId, | |
array | $usages = [] |
||
) |
int | $pageId | |
EntityUsage[] | $usages |
InvalidArgumentException |
Wikibase\Client\Usage\PageEntityUsages::__toString | ( | ) |
Wikibase\Client\Usage\PageEntityUsages::addUsages | ( | array | $usages | ) |
array | $usages |
InvalidArgumentException |
Wikibase\Client\Usage\PageEntityUsages::equals | ( | self | $other | ) |
self | $other |
Wikibase\Client\Usage\PageEntityUsages::getAspectKeys | ( | ) |
Collects all usage aspects present on the page.
Aspect keys will include modifiers, use getAspects() if modifiers are not desired.
Wikibase\Client\Usage\PageEntityUsages::getAspects | ( | ) |
Collects all usage aspects present on the page.
Modifiers are not considered, use getAspects() if modifiers should be included.
Wikibase\Client\Usage\PageEntityUsages::getEntityIds | ( | ) |
Returns all entities used on the page represented by this PageEntityUsages object.
Wikibase\Client\Usage\PageEntityUsages::getPageId | ( | ) |
Returns the page this PageEntityUsages object applies to.
Wikibase\Client\Usage\PageEntityUsages::getUsageAspectKeys | ( | EntityId | $id | ) |
Returns the aspects used by the given entity on the page represented by this PageEntityUsages object.
They aspects will include any modifiers.
EntityId | $id |
Wikibase\Client\Usage\PageEntityUsages::getUsages | ( | ) |
Wikibase\Client\Usage\PageEntityUsages::isEmpty | ( | ) |
|
private |
|
private |