Class FieldDef<I,​T>

  • Type Parameters:
    I - input type from which documents are created and search results are returned.
    T - type that should be extracted from the input object when converting to an index document.

    public final class FieldDef<I,​T>
    extends Object
    Definition of a field stored in the secondary index.
    • Method Detail

      • getName

        public String getName()
        Returns:
        name of the field.
      • getType

        public FieldType<?> getType()
        Returns:
        type of the field; for repeatable fields, the inner type, not the iterable type.
      • isStored

        public boolean isStored()
        Returns:
        whether the field should be stored in the index.
      • get

        public T get​(I input)
              throws com.google.gwtorm.server.OrmException
        Get the field contents from the input object.
        Parameters:
        input - input object.
        Returns:
        the field value(s) to index.
        Throws:
        com.google.gwtorm.server.OrmException
      • isRepeatable

        public boolean isRepeatable()
        Returns:
        whether the field is repeatable.