Package org.openrefine.wikibase.editing
Class NewEntityLibrary
- java.lang.Object
-
- org.openrefine.wikibase.editing.NewEntityLibrary
-
public class NewEntityLibrary extends Object
This keeps track of the new entities that we have created for each internal reconciliation id.- Author:
- Antonin Delpeuch
-
-
Constructor Summary
Constructors Constructor Description NewEntityLibrary()
NewEntityLibrary(Map<Long,String> map)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object other)
String
getId(long id)
Retrieves the id allocated to a given new cellMap<Long,String>
getIdMap()
Getter, only meant to be used by Jacksonint
hashCode()
void
setId(long id, String returnedId)
Stores an id associated to a new cellString
toString()
-
-
-
Method Detail
-
getId
public String getId(long id)
Retrieves the id allocated to a given new cell- Parameters:
id
- : the fake EntityId generated by the cell- Returns:
- the id (or null if unallocated yet)
-
setId
public void setId(long id, String returnedId)
Stores an id associated to a new cell- Parameters:
id
- : the internal reconciliation id of the new cellreturnedId
- : the associated id returned by Wikibase
-
getIdMap
public Map<Long,String> getIdMap()
Getter, only meant to be used by Jackson- Returns:
- the underlying map
-
-