Class Type.Builder

public static final class Type.Builder extends GeneratedMessageV3.Builder<Type.Builder> implements TypeOrBuilder

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

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public Type.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
Type.Builder
Overrides

build()

public Type build()
Returns
TypeDescription
Type

buildPartial()

public Type buildPartial()
Returns
TypeDescription
Type

clear()

public Type.Builder clear()
Returns
TypeDescription
Type.Builder
Overrides

clearArrayElementType()

public Type.Builder clearArrayElementType()

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()

public Type.Builder clearCode()

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)

public Type.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
Type.Builder
Overrides

clearOneof(Descriptors.OneofDescriptor oneof)

public Type.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
Type.Builder
Overrides

clearStructType()

public Type.Builder clearStructType()

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

clone()

public Type.Builder clone()
Returns
TypeDescription
Type.Builder
Overrides

getArrayElementType()

public Type getArrayElementType()

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()

public Type.Builder getArrayElementTypeBuilder()

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()

public TypeOrBuilder getArrayElementTypeOrBuilder()

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()

public TypeCode getCode()

Required. The TypeCode for this type.

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

Returns
TypeDescription
TypeCode

The code.

getCodeValue()

public int getCodeValue()

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()

public Type getDefaultInstanceForType()
Returns
TypeDescription
Type

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getStructType()

public StructType getStructType()

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()

public StructType.Builder getStructTypeBuilder()

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()

public StructTypeOrBuilder getStructTypeOrBuilder()

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

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

Returns
TypeDescription
StructTypeOrBuilder

hasArrayElementType()

public boolean hasArrayElementType()

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()

public boolean hasStructType()

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()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeArrayElementType(Type value)

public Type.Builder mergeArrayElementType(Type value)

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)

public Type.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
Type.Builder
Overrides Exceptions
TypeDescription
IOException

mergeFrom(Message other)

public Type.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
Type.Builder
Overrides

mergeFrom(Type other)

public Type.Builder mergeFrom(Type other)
Parameter
NameDescription
otherType
Returns
TypeDescription
Type.Builder

mergeStructType(StructType value)

public Type.Builder mergeStructType(StructType value)

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)

public final Type.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
Type.Builder
Overrides

setArrayElementType(Type value)

public Type.Builder setArrayElementType(Type value)

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)

public Type.Builder setArrayElementType(Type.Builder builderForValue)

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)

public Type.Builder setCode(TypeCode value)

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)

public Type.Builder setCodeValue(int value)

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)

public Type.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
Type.Builder
Overrides

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

public Type.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
Type.Builder
Overrides

setStructType(StructType value)

public Type.Builder setStructType(StructType value)

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)

public Type.Builder setStructType(StructType.Builder builderForValue)

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

setUnknownFields(UnknownFieldSet unknownFields)

public final Type.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
Type.Builder
Overrides