org.apache.nutch.indexer
Class NutchField

java.lang.Object
  extended by org.apache.nutch.indexer.NutchField
All Implemented Interfaces:
Writable

public class NutchField
extends Object
implements Writable

This class represents a multi-valued field with a weight. Values are arbitrary objects.


Constructor Summary
NutchField()
           
NutchField(Object value)
           
NutchField(Object value, float weight)
           
 
Method Summary
 void add(Object value)
           
 List<Object> getValues()
           
 float getWeight()
           
 void readFields(DataInput in)
           
 void reset()
           
 void setWeight(float weight)
           
 void write(DataOutput out)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NutchField

public NutchField()

NutchField

public NutchField(Object value)

NutchField

public NutchField(Object value,
                  float weight)
Method Detail

add

public void add(Object value)

getWeight

public float getWeight()

setWeight

public void setWeight(float weight)

getValues

public List<Object> getValues()

reset

public void reset()

readFields

public void readFields(DataInput in)
                throws IOException
Specified by:
readFields in interface Writable
Throws:
IOException

write

public void write(DataOutput out)
           throws IOException
Specified by:
write in interface Writable
Throws:
IOException


Copyright © 2011 The Apache Software Foundation