Class StructuredDataType

java.lang.Object
com.yahoo.vespa.objects.Selectable
com.yahoo.vespa.objects.Identifiable
com.yahoo.document.DataType
com.yahoo.document.StructuredDataType
All Implemented Interfaces:
Cloneable, Comparable<DataType>
Direct Known Subclasses:
BaseStructDataType, DocumentType

public abstract class StructuredDataType extends DataType
Author:
HÃ¥kon Humberset
  • Field Details

    • classId

      public static final int classId
  • Constructor Details

    • StructuredDataType

      public StructuredDataType(String name)
    • StructuredDataType

      public StructuredDataType(int id, String name)
  • Method Details

    • createId

      protected static int createId(String name)
    • createFieldValue

      public abstract StructuredFieldValue createFieldValue()
      Description copied from class: DataType
      Creates a new, empty FieldValue of this type
      Specified by:
      createFieldValue in class DataType
    • createByReflection

      protected FieldValue createByReflection(Object arg)
      Description copied from class: DataType
      Creates a field value by reflection
      Overrides:
      createByReflection in class DataType
      Parameters:
      arg - the value of the newly created field value
      Returns:
      a fully constructed value
    • getDataTypeName

      public DataTypeName getDataTypeName()
      Returns the name of this as a DataTypeName
      Returns:
      Return the Documentname of this doumenttype.
    • getField

      public abstract Field getField(String name)
      Gets the field matching a given name.
      Parameters:
      name - The name of a field.
      Returns:
      Returns the matching field, or null if not found.
    • getField

      public abstract Field getField(int id)
      Gets the field with the specified id.
      Parameters:
      id - the id of the field to return.
      Returns:
      the matching field, or null if not found.
    • getFields

      public abstract Collection<Field> getFields()
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class DataType
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class DataType
    • register

      protected void register(DocumentTypeManager manager, List<DataType> seenTypes)
      Overrides:
      register in class DataType
    • buildFieldPath

      public FieldPath buildFieldPath(String remainFieldName)
      Description copied from class: DataType
      Creates a field path from the given field path string.
      Overrides:
      buildFieldPath in class DataType
      Parameters:
      remainFieldName - a string containing the field path
      Returns:
      Returns a valid field path, parsed from the string