Class CollisionMap
java.lang.Object
org.apache.lucene.facet.taxonomy.writercache.CollisionMap
HashMap to store colliding labels. See
CompactLabelToOrdinal for
details.-
Method Summary
Modifier and TypeMethodDescriptionintaddLabel(FacetLabel label, int hash, int cid) Add another mapping.voidaddLabelOffset(int hash, int offset, int cid) This method does not check if the same value is already in the map because we pass in an char-array offset, so so we now that we're in resize-mode here.intcapacity()How many slots are allocated.intget(FacetLabel label, int hash) Return the mapping, orLabelToOrdinal.INVALID_ORDINALif the label isn't recognized.intsize()How many mappings.
-
Method Details
-
size
public int size()How many mappings. -
capacity
public int capacity()How many slots are allocated. -
get
Return the mapping, orLabelToOrdinal.INVALID_ORDINALif the label isn't recognized. -
addLabel
Add another mapping. -
addLabelOffset
public void addLabelOffset(int hash, int offset, int cid) This method does not check if the same value is already in the map because we pass in an char-array offset, so so we now that we're in resize-mode here.
-