Interface SqlType.Struct
- All Superinterfaces:
Serializable,SqlType<Struct>
- All Known Implementing Classes:
Type.SchemalessStruct,Type.StructWithSchema
Represents a struct type in SQL. A struct is an ordered collection of named and type fields.
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic interfaceRepresents a field in a structNested classes/interfaces inherited from interface com.google.cloud.bigtable.data.v2.models.sql.SqlType
SqlType.Array<Elem>, SqlType.Code, SqlType.Map<K,V>, SqlType.Struct -
Method Summary
Modifier and TypeMethodDescriptionintgetColumnIndex(String fieldName) List<? extends SqlType.Struct.Field>SqlType<?>getType(int fieldIndex) SqlType<?>
-
Method Details
-
getFields
List<? extends SqlType.Struct.Field> getFields()- Returns:
- the ordered list of
SqlType.Struct.Fields for the struct
-
getType
- Parameters:
fieldIndex- index of the field- Returns:
- the
SqlTypeof the field at the given index
-
getType
- Parameters:
fieldName- name of the field- Returns:
- the
SqlTypeof the field with the given name - Throws:
IllegalArgumentException- if there is no field with the name *or* if there are multiple columns with the given name
-
getColumnIndex
- Parameters:
fieldName- name of the field- Returns:
- the field index of the field with the given name
- Throws:
IllegalArgumentException- if there is no field with the name *or* if there are multiple columns with the given name
-