public class StatementUpdateImpl extends Object implements StatementUpdate
StatementUpdate
.StatementDocumentUpdateImpl
EMPTY
Constructor and Description |
---|
StatementUpdateImpl(Collection<Statement> added,
Collection<Statement> replaced,
Collection<String> removed)
Initializes new statement update.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object obj) |
List<Statement> |
getAdded()
Returns statements added to the entity in this update.
|
Set<String> |
getRemoved()
Returns IDs of statements removed from the entity in this update.
|
Map<String,Statement> |
getReplaced()
Returns entity statements modified in this update.
|
int |
hashCode() |
boolean |
isEmpty()
Checks whether the update is empty.
|
public StatementUpdateImpl(Collection<Statement> added, Collection<Statement> replaced, Collection<String> removed)
added
- added statementsreplaced
- replaced statementsremoved
- IDs of removed statementsNullPointerException
- if any parameter or any item is null
IllegalArgumentException
- if any parameters or their combination is invalidpublic boolean isEmpty()
StatementUpdate
isEmpty
in interface StatementUpdate
true
if the update is empty, false
otherwisepublic List<Statement> getAdded()
StatementUpdate
getAdded
in interface StatementUpdate
public Map<String,Statement> getReplaced()
StatementUpdate
getReplaced
in interface StatementUpdate
public Set<String> getRemoved()
StatementUpdate
getRemoved
in interface StatementUpdate
Copyright © 2014–2024 Wikidata Toolkit Developers. Generated from source code published under the Apache License 2.0. For more information, see the Wikidata Toolkit homepage