|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.terrier.structures.Lexicon<String>
org.terrier.structures.MapLexicon
org.terrier.structures.FSOMapFileLexicon
public class FSOMapFileLexicon
Instance of a Lexicon where a FSOrderedMapFile is always used as a backing store.
Index Properties:
| Nested Class Summary | |
|---|---|
static class |
FSOMapFileLexicon.MapFileLexiconEntryIterator
Iterate through the values in order |
static class |
FSOMapFileLexicon.MapFileLexiconIterator
An iterator over the lexicon |
| Nested classes/interfaces inherited from class org.terrier.structures.MapLexicon |
|---|
MapLexicon.Id2EntryIndexLookup, MapLexicon.IdIsIndex |
| Field Summary |
|---|
| Fields inherited from class org.terrier.structures.MapLexicon |
|---|
keyFactory |
| Constructor Summary | |
|---|---|
FSOMapFileLexicon(String structureName,
Index index)
Construct a new FSOMapFileLexicon |
|
FSOMapFileLexicon(String structureName,
String path,
String prefix,
FixedSizeWriteableFactory<org.apache.hadoop.io.Text> _keyFactory,
FixedSizeWriteableFactory<LexiconEntry> _valueFactory,
String termIdLookup,
String termLookup,
String dataFile)
Construct an instance of the class with |
|
| Method Summary | |
|---|---|
void |
close()
|
static String |
constructFilename(String structureName,
String path,
String prefix,
String extension)
Constructs a filename |
static void |
deleteMapFileLexicon(String structureName,
String path,
String prefix)
Delete a FSOMapFileLexicon within the specified index location |
Iterator<Map.Entry<String,LexiconEntry>> |
iterator()
|
static void |
optimise(String structureName,
Index index,
LexiconBuilder.CollectionStatisticsCounter statsCounter)
Does two things to a FSOMapFileLexicon: adds the termid lookup file (if required), and also creates the lexicon has file. |
static void |
optimise(String structureName,
Index index,
LexiconBuilder.CollectionStatisticsCounter statsCounter,
int numEntries)
optimise |
static void |
renameMapFileLexicon(String SrcStructureName,
String SrcPath,
String SrcPrefix,
String destStructureName,
String destPath,
String destPrefix)
Rename a FSOMapFileLexicon within the specified index location |
| Methods inherited from class org.terrier.structures.MapLexicon |
|---|
getIthLexiconEntry, getLexiconEntry, getLexiconEntry, getLexiconEntryRange, numberOfEntries, setTermIdLookup |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public FSOMapFileLexicon(String structureName,
Index index)
throws IOException
IOException
public FSOMapFileLexicon(String structureName,
String path,
String prefix,
FixedSizeWriteableFactory<org.apache.hadoop.io.Text> _keyFactory,
FixedSizeWriteableFactory<LexiconEntry> _valueFactory,
String termIdLookup,
String termLookup,
String dataFile)
throws IOException
structureName - path - prefix - _keyFactory - _valueFactory - termIdLookup - termLookup - dataFile -
IOException| Method Detail |
|---|
public void close()
throws IOException
MapLexicon
close in interface Closeableclose in class MapLexiconIOExceptionpublic Iterator<Map.Entry<String,LexiconEntry>> iterator()
public static void optimise(String structureName,
Index index,
LexiconBuilder.CollectionStatisticsCounter statsCounter)
throws IOException
structureName - - name of the index structure that this FSOMapFileLexicon representsindex - - the index that the index belongs
IOException - if an IO problem occurs
public static void optimise(String structureName,
Index index,
LexiconBuilder.CollectionStatisticsCounter statsCounter,
int numEntries)
throws IOException
structureName - index - statsCounter - numEntries -
IOException
public static String constructFilename(String structureName,
String path,
String prefix,
String extension)
structureName - path - prefix - extension -
public static void renameMapFileLexicon(String SrcStructureName,
String SrcPath,
String SrcPrefix,
String destStructureName,
String destPath,
String destPrefix)
public static void deleteMapFileLexicon(String structureName,
String path,
String prefix)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||