Class EntityRedirectDocumentImpl
java.lang.Object
org.wikidata.wdtk.datamodel.implementation.EntityRedirectDocumentImpl
- All Implemented Interfaces:
EntityDocument
,EntityRedirectDocument
Implementation of
EntityRedirectDocument
- Author:
- Thomas Pellissier Tanon
-
Method Summary
Modifier and TypeMethodDescriptionboolean
Returns the ID of the entity that the data refers tolong
Returns the revision ID of this document, or 0 if no id is known.Returns the ID of the entity that the redirection target to.int
hashCode()
toString()
withRevisionId
(long newRevisionId) Returns a copy of this document with an updated revision id.
-
Method Details
-
getEntityId
Description copied from interface:EntityDocument
Returns the ID of the entity that the data refers to- Specified by:
getEntityId
in interfaceEntityDocument
- Returns:
- entity id
-
getRevisionId
public long getRevisionId()Description copied from interface:EntityDocument
Returns the revision ID of this document, or 0 if no id is known. The revision ID is a number stored by MediaWiki to indicate the version of a document. It is based on a global counter that is incremented on each edit. Not all sources of entity document data may provide the revision ID, as it is not strictly part of the data, but part of the document metadata.- Specified by:
getRevisionId
in interfaceEntityDocument
- Returns:
- revision id
-
withRevisionId
Description copied from interface:EntityDocument
Returns a copy of this document with an updated revision id.- Specified by:
withRevisionId
in interfaceEntityDocument
- Specified by:
withRevisionId
in interfaceEntityRedirectDocument
-
getTargetId
Description copied from interface:EntityRedirectDocument
Returns the ID of the entity that the redirection target to.- Specified by:
getTargetId
in interfaceEntityRedirectDocument
- Returns:
- entity id
-
hashCode
public int hashCode() -
equals
-
toString
-