Class Type.Builder (6.89.0)

publicstaticfinalclassType.BuilderextendsGeneratedMessageV3.Builder<Type.Builder>implementsTypeOrBuilder

Type indicates the type of a Cloud Spanner value, as might be stored in a table cell or returned from an SQL query.

Protobuf type google.spanner.v1.Type

Implements

TypeOrBuilder

Static Methods

getDescriptor()

publicstaticfinalDescriptors.DescriptorgetDescriptor()
Returns
TypeDescription
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

publicType.BuilderaddRepeatedField(Descriptors.FieldDescriptorfield,Objectvalue)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
Type.Builder
Overrides

build()

publicTypebuild()
Returns
TypeDescription
Type

buildPartial()

publicTypebuildPartial()
Returns
TypeDescription
Type

clear()

publicType.Builderclear()
Returns
TypeDescription
Type.Builder
Overrides

clearArrayElementType()

publicType.BuilderclearArrayElementType()

If code == ARRAY, then array_element_type is the type of the array elements.

.google.spanner.v1.Type array_element_type = 2;

Returns
TypeDescription
Type.Builder

clearCode()

publicType.BuilderclearCode()

Required. The TypeCode for this type.

.google.spanner.v1.TypeCode code = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
Type.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

publicType.BuilderclearField(Descriptors.FieldDescriptorfield)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
Type.Builder
Overrides

clearOneof(Descriptors.OneofDescriptor oneof)

publicType.BuilderclearOneof(Descriptors.OneofDescriptoroneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
Type.Builder
Overrides

clearProtoTypeFqn()

publicType.BuilderclearProtoTypeFqn()

If code == PROTO or code == ENUM, then proto_type_fqn is the fully qualified name of the proto type representing the proto/enum definition.

string proto_type_fqn = 5;

Returns
TypeDescription
Type.Builder

This builder for chaining.

clearStructType()

publicType.BuilderclearStructType()

If code == STRUCT, then struct_type provides type information for the struct's fields.

.google.spanner.v1.StructType struct_type = 3;

Returns
TypeDescription
Type.Builder

clearTypeAnnotation()

publicType.BuilderclearTypeAnnotation()

The TypeAnnotationCode that disambiguates SQL type that Spanner will use to represent values of this type during query processing. This is necessary for some type codes because a single TypeCode can be mapped to different SQL types depending on the SQL dialect. type_annotation typically is not needed to process the content of a value (it doesn't affect serialization) and clients can ignore it on the read path.

.google.spanner.v1.TypeAnnotationCode type_annotation = 4;

Returns
TypeDescription
Type.Builder

This builder for chaining.

clone()

publicType.Builderclone()
Returns
TypeDescription
Type.Builder
Overrides

getArrayElementType()

publicTypegetArrayElementType()

If code == ARRAY, then array_element_type is the type of the array elements.

.google.spanner.v1.Type array_element_type = 2;

Returns
TypeDescription
Type

The arrayElementType.

getArrayElementTypeBuilder()

publicType.BuildergetArrayElementTypeBuilder()

If code == ARRAY, then array_element_type is the type of the array elements.

.google.spanner.v1.Type array_element_type = 2;

Returns
TypeDescription
Type.Builder

getArrayElementTypeOrBuilder()

publicTypeOrBuildergetArrayElementTypeOrBuilder()

If code == ARRAY, then array_element_type is the type of the array elements.

.google.spanner.v1.Type array_element_type = 2;

Returns
TypeDescription
TypeOrBuilder

getCode()

publicTypeCodegetCode()

Required. The TypeCode for this type.

.google.spanner.v1.TypeCode code = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
TypeCode

The code.

getCodeValue()

publicintgetCodeValue()

Required. The TypeCode for this type.

.google.spanner.v1.TypeCode code = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
int

The enum numeric value on the wire for code.

getDefaultInstanceForType()

publicTypegetDefaultInstanceForType()
Returns
TypeDescription
Type

getDescriptorForType()

publicDescriptors.DescriptorgetDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getProtoTypeFqn()

publicStringgetProtoTypeFqn()

If code == PROTO or code == ENUM, then proto_type_fqn is the fully qualified name of the proto type representing the proto/enum definition.

string proto_type_fqn = 5;

Returns
TypeDescription
String

The protoTypeFqn.

getProtoTypeFqnBytes()

publicByteStringgetProtoTypeFqnBytes()

If code == PROTO or code == ENUM, then proto_type_fqn is the fully qualified name of the proto type representing the proto/enum definition.

string proto_type_fqn = 5;

Returns
TypeDescription
ByteString

The bytes for protoTypeFqn.

getStructType()

publicStructTypegetStructType()

If code == STRUCT, then struct_type provides type information for the struct's fields.

.google.spanner.v1.StructType struct_type = 3;

Returns
TypeDescription
StructType

The structType.

getStructTypeBuilder()

publicStructType.BuildergetStructTypeBuilder()

If code == STRUCT, then struct_type provides type information for the struct's fields.

.google.spanner.v1.StructType struct_type = 3;

Returns
TypeDescription
StructType.Builder

getStructTypeOrBuilder()

publicStructTypeOrBuildergetStructTypeOrBuilder()

If code == STRUCT, then struct_type provides type information for the struct's fields.

.google.spanner.v1.StructType struct_type = 3;

Returns
TypeDescription
StructTypeOrBuilder

getTypeAnnotation()

publicTypeAnnotationCodegetTypeAnnotation()

The TypeAnnotationCode that disambiguates SQL type that Spanner will use to represent values of this type during query processing. This is necessary for some type codes because a single TypeCode can be mapped to different SQL types depending on the SQL dialect. type_annotation typically is not needed to process the content of a value (it doesn't affect serialization) and clients can ignore it on the read path.

.google.spanner.v1.TypeAnnotationCode type_annotation = 4;

Returns
TypeDescription
TypeAnnotationCode

The typeAnnotation.

getTypeAnnotationValue()

publicintgetTypeAnnotationValue()

The TypeAnnotationCode that disambiguates SQL type that Spanner will use to represent values of this type during query processing. This is necessary for some type codes because a single TypeCode can be mapped to different SQL types depending on the SQL dialect. type_annotation typically is not needed to process the content of a value (it doesn't affect serialization) and clients can ignore it on the read path.

.google.spanner.v1.TypeAnnotationCode type_annotation = 4;

Returns
TypeDescription
int

The enum numeric value on the wire for typeAnnotation.

hasArrayElementType()

publicbooleanhasArrayElementType()

If code == ARRAY, then array_element_type is the type of the array elements.

.google.spanner.v1.Type array_element_type = 2;

Returns
TypeDescription
boolean

Whether the arrayElementType field is set.

hasStructType()

publicbooleanhasStructType()

If code == STRUCT, then struct_type provides type information for the struct's fields.

.google.spanner.v1.StructType struct_type = 3;

Returns
TypeDescription
boolean

Whether the structType field is set.

internalGetFieldAccessorTable()

protectedGeneratedMessageV3.FieldAccessorTableinternalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

publicfinalbooleanisInitialized()
Returns
TypeDescription
boolean
Overrides

mergeArrayElementType(Type value)

publicType.BuildermergeArrayElementType(Typevalue)

If code == ARRAY, then array_element_type is the type of the array elements.

.google.spanner.v1.Type array_element_type = 2;

Parameter
NameDescription
valueType
Returns
TypeDescription
Type.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

publicType.BuildermergeFrom(CodedInputStreaminput,ExtensionRegistryLiteextensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
Type.Builder
Overrides
Exceptions
TypeDescription
IOException

mergeFrom(Message other)

publicType.BuildermergeFrom(Messageother)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
Type.Builder
Overrides

mergeFrom(Type other)

publicType.BuildermergeFrom(Typeother)
Parameter
NameDescription
otherType
Returns
TypeDescription
Type.Builder

mergeStructType(StructType value)

publicType.BuildermergeStructType(StructTypevalue)

If code == STRUCT, then struct_type provides type information for the struct's fields.

.google.spanner.v1.StructType struct_type = 3;

Parameter
NameDescription
valueStructType
Returns
TypeDescription
Type.Builder

mergeUnknownFields(UnknownFieldSet unknownFields)

publicfinalType.BuildermergeUnknownFields(UnknownFieldSetunknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
Type.Builder
Overrides

setArrayElementType(Type value)

publicType.BuildersetArrayElementType(Typevalue)

If code == ARRAY, then array_element_type is the type of the array elements.

.google.spanner.v1.Type array_element_type = 2;

Parameter
NameDescription
valueType
Returns
TypeDescription
Type.Builder

setArrayElementType(Type.Builder builderForValue)

publicType.BuildersetArrayElementType(Type.BuilderbuilderForValue)

If code == ARRAY, then array_element_type is the type of the array elements.

.google.spanner.v1.Type array_element_type = 2;

Parameter
NameDescription
builderForValueType.Builder
Returns
TypeDescription
Type.Builder

setCode(TypeCode value)

publicType.BuildersetCode(TypeCodevalue)

Required. The TypeCode for this type.

.google.spanner.v1.TypeCode code = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
valueTypeCode

The code to set.

Returns
TypeDescription
Type.Builder

This builder for chaining.

setCodeValue(int value)

publicType.BuildersetCodeValue(intvalue)

Required. The TypeCode for this type.

.google.spanner.v1.TypeCode code = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
valueint

The enum numeric value on the wire for code to set.

Returns
TypeDescription
Type.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

publicType.BuildersetField(Descriptors.FieldDescriptorfield,Objectvalue)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
Type.Builder
Overrides

setProtoTypeFqn(String value)

publicType.BuildersetProtoTypeFqn(Stringvalue)

If code == PROTO or code == ENUM, then proto_type_fqn is the fully qualified name of the proto type representing the proto/enum definition.

string proto_type_fqn = 5;

Parameter
NameDescription
valueString

The protoTypeFqn to set.

Returns
TypeDescription
Type.Builder

This builder for chaining.

setProtoTypeFqnBytes(ByteString value)

publicType.BuildersetProtoTypeFqnBytes(ByteStringvalue)

If code == PROTO or code == ENUM, then proto_type_fqn is the fully qualified name of the proto type representing the proto/enum definition.

string proto_type_fqn = 5;

Parameter
NameDescription
valueByteString

The bytes for protoTypeFqn to set.

Returns
TypeDescription
Type.Builder

This builder for chaining.

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

publicType.BuildersetRepeatedField(Descriptors.FieldDescriptorfield,intindex,Objectvalue)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
Type.Builder
Overrides

setStructType(StructType value)

publicType.BuildersetStructType(StructTypevalue)

If code == STRUCT, then struct_type provides type information for the struct's fields.

.google.spanner.v1.StructType struct_type = 3;

Parameter
NameDescription
valueStructType
Returns
TypeDescription
Type.Builder

setStructType(StructType.Builder builderForValue)

publicType.BuildersetStructType(StructType.BuilderbuilderForValue)

If code == STRUCT, then struct_type provides type information for the struct's fields.

.google.spanner.v1.StructType struct_type = 3;

Parameter
NameDescription
builderForValueStructType.Builder
Returns
TypeDescription
Type.Builder

setTypeAnnotation(TypeAnnotationCode value)

publicType.BuildersetTypeAnnotation(TypeAnnotationCodevalue)

The TypeAnnotationCode that disambiguates SQL type that Spanner will use to represent values of this type during query processing. This is necessary for some type codes because a single TypeCode can be mapped to different SQL types depending on the SQL dialect. type_annotation typically is not needed to process the content of a value (it doesn't affect serialization) and clients can ignore it on the read path.

.google.spanner.v1.TypeAnnotationCode type_annotation = 4;

Parameter
NameDescription
valueTypeAnnotationCode

The typeAnnotation to set.

Returns
TypeDescription
Type.Builder

This builder for chaining.

setTypeAnnotationValue(int value)

publicType.BuildersetTypeAnnotationValue(intvalue)

The TypeAnnotationCode that disambiguates SQL type that Spanner will use to represent values of this type during query processing. This is necessary for some type codes because a single TypeCode can be mapped to different SQL types depending on the SQL dialect. type_annotation typically is not needed to process the content of a value (it doesn't affect serialization) and clients can ignore it on the read path.

.google.spanner.v1.TypeAnnotationCode type_annotation = 4;

Parameter
NameDescription
valueint

The enum numeric value on the wire for typeAnnotation to set.

Returns
TypeDescription
Type.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

publicfinalType.BuildersetUnknownFields(UnknownFieldSetunknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
Type.Builder
Overrides