|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.terrier.structures.seralization.FixedSizeTextFactory
public class FixedSizeTextFactory
Makes a Text object that has a fixed size when written using Writable methods.
Text,
FixedSizeWriteableFactory,
Writable| Field Summary | |
|---|---|
protected static org.apache.log4j.Logger |
logger
|
| Constructor Summary | |
|---|---|
FixedSizeTextFactory(int _termLength)
Make a factory object with the specified length |
|
FixedSizeTextFactory(java.lang.String _termLength)
Make a factory object with the specified length, decoded using Integer.parseInt() |
|
| Method Summary | |
|---|---|
static int |
getMaximumTextLength(int charCount)
For the Hadoop Text class, given a String of charCount, how long is the maximum encoded bytes? |
int |
getSize()
Returns the size of instance of this class when written using Writable |
org.apache.hadoop.io.Text |
newInstance()
Returns a new instance of Text with desired properties |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected static final org.apache.log4j.Logger logger
| Constructor Detail |
|---|
public FixedSizeTextFactory(java.lang.String _termLength)
public FixedSizeTextFactory(int _termLength)
| Method Detail |
|---|
public int getSize()
getSize in interface FixedSizeWriteableFactory<org.apache.hadoop.io.Text>public static int getMaximumTextLength(int charCount)
charCount - maximum length of the String
public org.apache.hadoop.io.Text newInstance()
newInstance in interface WriteableFactory<org.apache.hadoop.io.Text>
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||