Represents a single Wikibase item.
More...
◆ __construct()
- Since
- 1.0
- Parameters
-
ItemId | null | $id | |
Fingerprint | null | $fingerprint | |
SiteLinkList | null | $siteLinks | |
StatementList | null | $statements | |
◆ __clone()
Wikibase\DataModel\Entity\Item::__clone |
( |
| ) |
|
◆ addSiteLink()
Wikibase\DataModel\Entity\Item::addSiteLink |
( |
SiteLink | $siteLink | ) |
|
Adds a site link to the list of site links.
If there already is a site link with the site id of the provided site link, then that one will be overridden by the provided one.
- Since
- 0.6
- Parameters
-
◆ clear()
Wikibase\DataModel\Entity\Item::clear |
( |
| ) |
|
◆ copy()
Wikibase\DataModel\Entity\Item::copy |
( |
| ) |
|
◆ equals()
Wikibase\DataModel\Entity\Item::equals |
( |
| $target | ) |
|
◆ getAliasGroups()
Wikibase\DataModel\Entity\Item::getAliasGroups |
( |
| ) |
|
◆ getDescriptions()
Wikibase\DataModel\Entity\Item::getDescriptions |
( |
| ) |
|
◆ getFingerprint()
Wikibase\DataModel\Entity\Item::getFingerprint |
( |
| ) |
|
◆ getId()
Wikibase\DataModel\Entity\Item::getId |
( |
| ) |
|
◆ getLabels()
Wikibase\DataModel\Entity\Item::getLabels |
( |
| ) |
|
◆ getSiteLink()
Wikibase\DataModel\Entity\Item::getSiteLink |
( |
| $siteId | ) |
|
- Since
- 0.6
- Parameters
-
- Returns
- SiteLink
- Exceptions
-
◆ getSiteLinkList()
Wikibase\DataModel\Entity\Item::getSiteLinkList |
( |
| ) |
|
- Since
- 0.8
- Returns
- SiteLinkList
◆ getStatements()
Wikibase\DataModel\Entity\Item::getStatements |
( |
| ) |
|
◆ getType()
Wikibase\DataModel\Entity\Item::getType |
( |
| ) |
|
◆ hasLinkToSite()
Wikibase\DataModel\Entity\Item::hasLinkToSite |
( |
| $siteId | ) |
|
- Since
- 0.4
- Parameters
-
- Returns
- bool
◆ isEmpty()
Wikibase\DataModel\Entity\Item::isEmpty |
( |
| ) |
|
◆ newEmpty()
static Wikibase\DataModel\Entity\Item::newEmpty |
( |
| ) |
|
|
static |
- Deprecated
- since 2.5, use new Item() instead.
- Returns
- self
◆ removeSiteLink()
Wikibase\DataModel\Entity\Item::removeSiteLink |
( |
| $siteId | ) |
|
Removes the sitelink with specified site ID if the Item has such a sitelink.
- Since
- 0.1
- Parameters
-
string | $siteId | the target site's id |
◆ setAliases()
Wikibase\DataModel\Entity\Item::setAliases |
( |
| $languageCode, |
|
|
array | $aliases ) |
- Parameters
-
string | $languageCode | |
string[] | $aliases | |
- Exceptions
-
◆ setDescription()
Wikibase\DataModel\Entity\Item::setDescription |
( |
| $languageCode, |
|
|
| $value ) |
- Parameters
-
string | $languageCode | |
string | $value | |
- Exceptions
-
◆ setFingerprint()
Wikibase\DataModel\Entity\Item::setFingerprint |
( |
Fingerprint | $fingerprint | ) |
|
◆ setId()
Wikibase\DataModel\Entity\Item::setId |
( |
| $id | ) |
|
◆ setLabel()
Wikibase\DataModel\Entity\Item::setLabel |
( |
| $languageCode, |
|
|
| $value ) |
- Parameters
-
string | $languageCode | |
string | $value | |
- Exceptions
-
◆ setSiteLinkList()
Wikibase\DataModel\Entity\Item::setSiteLinkList |
( |
SiteLinkList | $siteLinks | ) |
|
◆ setStatements()
Wikibase\DataModel\Entity\Item::setStatements |
( |
StatementList | $statements | ) |
|
◆ $fingerprint
Wikibase\DataModel\Entity\Item::$fingerprint |
|
private |
◆ $id
Wikibase\DataModel\Entity\Item::$id |
|
private |
◆ $siteLinks
Wikibase\DataModel\Entity\Item::$siteLinks |
|
private |
◆ $statements
Wikibase\DataModel\Entity\Item::$statements |
|
private |
◆ ENTITY_TYPE
const Wikibase\DataModel\Entity\Item::ENTITY_TYPE = 'item' |
The documentation for this class was generated from the following file:
- lib/packages/wikibase/data-model/src/Entity/Item.php