|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.terrier.structures.postings.BasicPostingImpl org.terrier.structures.postings.FieldPostingImpl
public class FieldPostingImpl
Implementation of a posting containing fields
Field Summary |
---|
Fields inherited from class org.terrier.structures.postings.BasicPostingImpl |
---|
id, tf |
Constructor Summary | |
---|---|
FieldPostingImpl()
default constructor |
|
FieldPostingImpl(int _fieldCount)
constructor |
|
FieldPostingImpl(int[] _fieldFrequencies)
constructor |
|
FieldPostingImpl(int id,
int tf,
int _fieldCount)
constructor |
|
FieldPostingImpl(int id,
int tf,
int[] _fieldFrequencies)
constructor |
Method Summary | |
---|---|
WritablePosting |
asWritablePosting()
Copies this posting to one free of an iterator. |
int[] |
getFieldFrequencies()
Returns the frequencies of the term in each field of the document |
int[] |
getFieldLengths()
Returns the lengths of the each fields in the current document |
void |
readFields(java.io.DataInput in)
Reads the a single posting (not an iterable posting - use BitPostingIndex for that) |
java.lang.String |
toString()
Makes a human readable form of this posting |
void |
write(java.io.DataOutput out)
Writes the current posting (not an iterable posting - use DirectInvertedOutputStream for that). |
Methods inherited from class org.terrier.structures.postings.BasicPostingImpl |
---|
getDocumentLength, getFrequency, getId, setId |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface org.terrier.structures.postings.Posting |
---|
getDocumentLength, getFrequency, getId, setId |
Constructor Detail |
---|
public FieldPostingImpl()
public FieldPostingImpl(int id, int tf, int _fieldCount)
id
- tf
- _fieldCount
- public FieldPostingImpl(int id, int tf, int[] _fieldFrequencies)
id
- tf
- _fieldFrequencies
- public FieldPostingImpl(int[] _fieldFrequencies)
_fieldFrequencies
- public FieldPostingImpl(int _fieldCount)
_fieldCount
- Method Detail |
---|
public int[] getFieldFrequencies()
getFieldFrequencies
in interface FieldPosting
public int[] getFieldLengths()
getFieldLengths
in interface FieldPosting
public void readFields(java.io.DataInput in) throws java.io.IOException
readFields
in interface org.apache.hadoop.io.Writable
readFields
in class BasicPostingImpl
java.io.IOException
public void write(java.io.DataOutput out) throws java.io.IOException
BasicPostingImpl
write
in interface org.apache.hadoop.io.Writable
write
in class BasicPostingImpl
java.io.IOException
public WritablePosting asWritablePosting()
asWritablePosting
in interface Posting
asWritablePosting
in class BasicPostingImpl
public java.lang.String toString()
toString
in class BasicPostingImpl
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |