Class 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 Detail

      • NewEntityLibrary

        public NewEntityLibrary()
      • NewEntityLibrary

        public NewEntityLibrary​(Map<Long,​String> map)
    • 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 cell
        returnedId - : the associated id returned by Wikibase
      • getIdMap

        public Map<Long,​String> getIdMap()
        Getter, only meant to be used by Jackson
        Returns:
        the underlying map
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object