Class ComplexAttributeFieldUtils

java.lang.Object
com.yahoo.schema.document.ComplexAttributeFieldUtils

public class ComplexAttributeFieldUtils extends Object
Utils used to check whether a complex field supports being represented as struct field attributes. Currently we support: - array of simple struct - map of primitive type to simple struct - map of primitive type to primitive type A simple struct can contain fields of any type, but only fields of primitive type can be defined as struct field attributes in the complex field using the simple struct.
Author:
geirst
  • Constructor Details

    • ComplexAttributeFieldUtils

      public ComplexAttributeFieldUtils()
  • Method Details

    • isSupportedComplexField

      public static boolean isSupportedComplexField(ImmutableSDField field)
    • isArrayOfSimpleStruct

      public static boolean isArrayOfSimpleStruct(ImmutableSDField field)
    • isMapOfSimpleStruct

      public static boolean isMapOfSimpleStruct(ImmutableSDField field)
    • isMapOfPrimitiveType

      public static boolean isMapOfPrimitiveType(ImmutableSDField field)
    • isPrimitiveType

      public static boolean isPrimitiveType(Attribute attribute)
    • isPrimitiveType

      public static boolean isPrimitiveType(com.yahoo.document.DataType dataType)
    • isComplexFieldWithOnlyStructFieldAttributes

      public static boolean isComplexFieldWithOnlyStructFieldAttributes(ImmutableSDField field)