Package org.apache.beam.sdk.schemas
Class Schema.Field
java.lang.Object
org.apache.beam.sdk.schemas.Schema.Field
- All Implemented Interfaces:
Serializable
- Enclosing class:
Schema
Field of a row. Contains the
Schema.FieldType along with associated metadata.- See Also:
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanabstract StringReturns the field's description.abstract StringgetName()Returns the field name.abstract Schema.OptionsReturns the fieldsSchema.Options.abstract Schema.FieldTypegetType()Returns the fieldsSchema.FieldType.final inthashCode()static Schema.Fieldnullable(String name, Schema.FieldType fieldType) Return's a nullable field with the give name and type.static Schema.Fieldof(String name, Schema.FieldType fieldType) Return's a field with the give name and type.abstract Schema.Field.BuilderbooleantypesEqual(Schema.Field other) Returns true if two fields are equal, ignoring name and description.withDescription(String description) Returns a copy of the Field with the description set.Returns a copy of the Field with the name set.withNullable(boolean isNullable) Returns a copy of the Field with isNullable set.withOptions(Schema.Options options) Returns a copy of the Field with the options set.withOptions(Schema.Options.Builder optionsBuilder) Returns a copy of the Field with the options set.withType(Schema.FieldType fieldType) Returns a copy of the Field with theSchema.FieldTypeset.
-
Constructor Details
-
Field
public Field()
-
-
Method Details
-
getName
Returns the field name. -
getDescription
Returns the field's description. -
getType
Returns the fieldsSchema.FieldType. -
getOptions
Returns the fieldsSchema.Options. -
toBuilder
-
of
Return's a field with the give name and type. -
nullable
Return's a nullable field with the give name and type. -
withName
Returns a copy of the Field with the name set. -
withDescription
Returns a copy of the Field with the description set. -
withType
Returns a copy of the Field with theSchema.FieldTypeset. -
withNullable
Returns a copy of the Field with isNullable set. -
withOptions
Returns a copy of the Field with the options set. -
withOptions
Returns a copy of the Field with the options set. -
equals
-
typesEqual
Returns true if two fields are equal, ignoring name and description. -
hashCode
public final int hashCode()
-