Interface LabeledStatementDocument
- All Superinterfaces:
EntityDocument
,LabeledDocument
,StatementDocument
- All Known Subinterfaces:
ItemDocument
,MediaInfoDocument
,PropertyDocument
,TermedStatementDocument
- All Known Implementing Classes:
ItemDocumentImpl
,MediaInfoDocumentImpl
,PropertyDocumentImpl
,TermedStatementDocumentImpl
This interface just joins
LabeledDocument
and StatementDocument
.
It is necessary to introduce this interface because the conflict between
the return types of the withRevisionId method in both interfaces needs to be resolved.- Author:
- Thomas Pellissier Tanon
-
Method Summary
Modifier and TypeMethodDescriptionwithLabel
(MonolingualTextValue newLabel) Returns a new version of this document with a new label (which overrides any existing label for this language).withoutStatementIds
(Set<String> statementIds) Returns a new version of this document where all statements matching any of the statement ids provided have been removed.withRevisionId
(long newRevisionId) Returns a copy of this document with an updated revision id.withStatement
(Statement statement) Returns a new version of this document which includes the statement provided.Methods inherited from interface org.wikidata.wdtk.datamodel.interfaces.EntityDocument
getEntityId, getRevisionId
Methods inherited from interface org.wikidata.wdtk.datamodel.interfaces.LabeledDocument
findLabel, getLabels
Methods inherited from interface org.wikidata.wdtk.datamodel.interfaces.StatementDocument
findStatement, findStatement, findStatementEntityIdValue, findStatementEntityIdValue, findStatementGlobeCoordinatesValue, findStatementGlobeCoordinatesValue, findStatementGroup, findStatementGroup, findStatementItemIdValue, findStatementItemIdValue, findStatementMonolingualTextValue, findStatementMonolingualTextValue, findStatementPropertyIdValue, findStatementPropertyIdValue, findStatementQuantityValue, findStatementQuantityValue, findStatementStringValue, findStatementStringValue, findStatementTimeValue, findStatementTimeValue, findStatementValue, findStatementValue, getAllStatements, getStatementGroups, hasStatement, hasStatement, hasStatementValue, hasStatementValue, hasStatementValue, hasStatementValue
-
Method Details
-
withRevisionId
Description copied from interface:LabeledDocument
Returns a copy of this document with an updated revision id.- Specified by:
withRevisionId
in interfaceEntityDocument
- Specified by:
withRevisionId
in interfaceLabeledDocument
- Specified by:
withRevisionId
in interfaceStatementDocument
-
withLabel
Description copied from interface:LabeledDocument
Returns a new version of this document with a new label (which overrides any existing label for this language).- Specified by:
withLabel
in interfaceLabeledDocument
-
withStatement
Description copied from interface:StatementDocument
Returns a new version of this document which includes the statement provided. If the identifier of this statement matches that of any other statement for the same property, then the existing statement will be replaced by the new one. Otherwise, the new statement will be added at the end of the list of statements in this group.- Specified by:
withStatement
in interfaceStatementDocument
- Parameters:
statement
- the statement to add or update in the document
-
withoutStatementIds
Description copied from interface:StatementDocument
Returns a new version of this document where all statements matching any of the statement ids provided have been removed. These statements can use different properties.- Specified by:
withoutStatementIds
in interfaceStatementDocument
- Parameters:
statementIds
- the identifiers of the statements to remove
-