|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.sun.labs.minion.indexer.partition.DocEntryMapper
public class DocEntryMapper
A class that can be used to remap document IDs when merging dictionaries composed of document keys. The IDs for the document keys will be mapped from the IDs of their original partition to the IDs of the merged partition.
Field Summary | |
---|---|
protected int[] |
idMap
A mapping from old document IDs to new document IDs in this partition when garbage collection will occur. |
protected int |
start
The new starting ID for the document keys from this partition. |
Constructor Summary | |
---|---|
DocEntryMapper(int start,
int[] idMap)
Creates a entry mapper for the documents from one partition. |
Method Summary | |
---|---|
Entry |
map(Entry e)
Maps a entry from a single partition document dictionary to a merged partition document dictionary. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected int start
protected int[] idMap
null
Constructor Detail |
---|
public DocEntryMapper(int start, int[] idMap)
start
- The new starting ID for the document keys from this
partition. This will be used when there is no garbage collection
going on for the partition.idMap
- A mapping from old document IDs to new document IDs in
this partition when garbage collection will occur. A new ID of -1
indicates that the given key will not occur in the merged
partition. If there is no garbage collection under way for this
partition, then this element can be null
.Method Detail |
---|
public Entry map(Entry e)
map
in interface EntryMapper
e
- The entry to map.
null
if this entry should
not be included in a merged dictionary. It is up to classes using
the entry mapper to account for this case!
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |