org.apache.nutch.indexer

## Class NutchField

- java.lang.Object
- - org.apache.nutch.indexer.NutchField

- All Implemented Interfaces:
    java.lang.Cloneable, Writable

      public class NutchField
      extends java.lang.Object
      implements Writable, java.lang.Cloneable

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

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `NutchField()`
    `NutchField(java.lang.Object value)`
    `NutchField(java.lang.Object value, float weight)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `add(java.lang.Object value)`
    `NutchField` | `clone()`
    `java.util.List<java.lang.Object>` | `getValues()`
    `float` | `getWeight()`
    `void` | `readFields(java.io.DataInput in)`
    `void` | `reset()`
    `void` | `setWeight(float weight)`
    `java.lang.String` | `toString()`
    `void` | `write(java.io.DataOutput out)`

    - ### Methods inherited from class java.lang.Object

      `equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Constructor Detail

    - #### NutchField

          public NutchField()

    - #### NutchField

          public NutchField(java.lang.Object value)

    - #### NutchField

          public NutchField(java.lang.Object value,
                            float weight)

  - ### Method Detail

    - #### add

          public void add(java.lang.Object value)

    - #### getWeight

          public float getWeight()

    - #### setWeight

          public void setWeight(float weight)

    - #### getValues

          public java.util.List<java.lang.Object> getValues()

    - #### reset

          public void reset()

    - #### clone

          public NutchField clone()
                           throws java.lang.CloneNotSupportedException

      Overrides:
        `clone` in class `java.lang.Object`
      Throws:
        `java.lang.CloneNotSupportedException`

    - #### readFields

          public void readFields(java.io.DataInput in)
                          throws java.io.IOException

      Specified by:
        `readFields` in interface `Writable`
      Throws:
        `java.io.IOException`

    - #### write

          public void write(java.io.DataOutput out)
                     throws java.io.IOException

      Specified by:
        `write` in interface `Writable`
      Throws:
        `java.io.IOException`

    - #### toString

          public java.lang.String toString()

      Overrides:
        `toString` in class `java.lang.Object`

Copyright © 2019 The Apache Software Foundation