Package org.openrefine.wikidata.updates
Class MediaInfoEditBuilder
java.lang.Object
org.openrefine.wikidata.updates.MediaInfoEditBuilder
Constructs a
MediaInfoEdit incrementally.- Author:
- Antonin Delpeuch
-
Constructor Summary
ConstructorsConstructorDescriptionMediaInfoEditBuilder(org.wikidata.wdtk.datamodel.interfaces.EntityIdValue id) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionaddLabel(org.wikidata.wdtk.datamodel.interfaces.MonolingualTextValue label, boolean override) Adds a label to the entity.addLabels(Set<org.wikidata.wdtk.datamodel.interfaces.MonolingualTextValue> labels, boolean override) Adds a list of labels to the entity.addStatement(StatementEdit statement) Adds an update to a statement.addStatements(List<StatementEdit> statements) Add a list of statement, as inaddStatement(org.openrefine.wikidata.updates.StatementEdit).build()Constructs theMediaInfoEdit.
-
Constructor Details
-
MediaInfoEditBuilder
public MediaInfoEditBuilder(org.wikidata.wdtk.datamodel.interfaces.EntityIdValue id) Constructor.- Parameters:
id- the subject of the document. It can be a reconciled entity value for new entities.
-
-
Method Details
-
addStatement
Adds an update to a statement.- Parameters:
statement- the statement to add or update
-
addStatements
Add a list of statement, as inaddStatement(org.openrefine.wikidata.updates.StatementEdit).- Parameters:
statements- the statements to add
-
addLabel
public MediaInfoEditBuilder addLabel(org.wikidata.wdtk.datamodel.interfaces.MonolingualTextValue label, boolean override) Adds a label to the entity.- Parameters:
label- the label to addoverride- whether the label should be added even if there is already a label in that language
-
addLabels
public MediaInfoEditBuilder addLabels(Set<org.wikidata.wdtk.datamodel.interfaces.MonolingualTextValue> labels, boolean override) Adds a list of labels to the entity.- Parameters:
labels- the labels to addoverride- whether the label should be added even if there is already a label in that language
-
build
Constructs theMediaInfoEdit.- Returns:
-