public final class Type extends GeneratedMessage 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
Inherited Members
com.google.protobuf.GeneratedMessage.<ContainingT,T>newFileScopedGeneratedExtension(java.lang.Class<?>,com.google.protobuf.Message)
com.google.protobuf.GeneratedMessage.<ContainingT,T>newMessageScopedGeneratedExtension(com.google.protobuf.Message,int,java.lang.Class<?>,com.google.protobuf.Message)
com.google.protobuf.GeneratedMessage.<ListT>makeMutableCopy(ListT)
com.google.protobuf.GeneratedMessage.<ListT>makeMutableCopy(ListT,int)
com.google.protobuf.GeneratedMessage.<T>emptyList(java.lang.Class<T>)
com.google.protobuf.GeneratedMessage.<V>serializeBooleanMapTo(com.google.protobuf.CodedOutputStream,com.google.protobuf.MapField<java.lang.Boolean,V>,com.google.protobuf.MapEntry<java.lang.Boolean,V>,int)
com.google.protobuf.GeneratedMessage.<V>serializeIntegerMapTo(com.google.protobuf.CodedOutputStream,com.google.protobuf.MapField<java.lang.Integer,V>,com.google.protobuf.MapEntry<java.lang.Integer,V>,int)
com.google.protobuf.GeneratedMessage.<V>serializeLongMapTo(com.google.protobuf.CodedOutputStream,com.google.protobuf.MapField<java.lang.Long,V>,com.google.protobuf.MapEntry<java.lang.Long,V>,int)
com.google.protobuf.GeneratedMessage.<V>serializeStringMapTo(com.google.protobuf.CodedOutputStream,com.google.protobuf.MapField<java.lang.String,V>,com.google.protobuf.MapEntry<java.lang.String,V>,int)
com.google.protobuf.GeneratedMessage.canUseUnsafe()
com.google.protobuf.GeneratedMessage.emptyBooleanList()
com.google.protobuf.GeneratedMessage.emptyDoubleList()
com.google.protobuf.GeneratedMessage.emptyFloatList()
com.google.protobuf.GeneratedMessage.emptyIntList()
com.google.protobuf.GeneratedMessage.emptyLongList()
com.google.protobuf.GeneratedMessage.internalGetMapFieldReflection(int)
com.google.protobuf.GeneratedMessage.isStringEmpty(java.lang.Object)
com.google.protobuf.GeneratedMessage.mergeFromAndMakeImmutableInternal(com.google.protobuf.CodedInputStream,com.google.protobuf.ExtensionRegistryLite)
com.google.protobuf.GeneratedMessage.newInstance(com.google.protobuf.GeneratedMessage.UnusedPrivateParameter)
com.google.protobuf.GeneratedMessage.parseUnknownFieldProto3(com.google.protobuf.CodedInputStream,com.google.protobuf.UnknownFieldSet.Builder,com.google.protobuf.ExtensionRegistryLite,int)
Static Fields
ARRAY_ELEMENT_TYPE_FIELD_NUMBER
public static final int ARRAY_ELEMENT_TYPE_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
|
CODE_FIELD_NUMBER
public static final int CODE_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
|
PROTO_TYPE_FQN_FIELD_NUMBER
public static final int PROTO_TYPE_FQN_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
|
STRUCT_TYPE_FIELD_NUMBER
public static final int STRUCT_TYPE_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
|
TYPE_ANNOTATION_FIELD_NUMBER
public static final int TYPE_ANNOTATION_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
|
Static Methods
getDefaultInstance()
public static Type getDefaultInstance()
| Returns |
| Type |
Description |
Type |
|
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
newBuilder()
public static Type.Builder newBuilder()
newBuilder(Type prototype)
public static Type.Builder newBuilder(Type prototype)
| Parameter |
| Name |
Description |
prototype |
Type
|
public static Type parseDelimitedFrom(InputStream input)
| Returns |
| Type |
Description |
Type |
|
public static Type parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
| Returns |
| Type |
Description |
Type |
|
parseFrom(byte[] data)
public static Type parseFrom(byte[] data)
| Parameter |
| Name |
Description |
data |
byte[]
|
| Returns |
| Type |
Description |
Type |
|
parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
public static Type parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
| Returns |
| Type |
Description |
Type |
|
parseFrom(ByteString data)
public static Type parseFrom(ByteString data)
| Returns |
| Type |
Description |
Type |
|
parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static Type parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
| Returns |
| Type |
Description |
Type |
|
public static Type parseFrom(CodedInputStream input)
| Returns |
| Type |
Description |
Type |
|
public static Type parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
| Returns |
| Type |
Description |
Type |
|
public static Type parseFrom(InputStream input)
| Returns |
| Type |
Description |
Type |
|
public static Type parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
| Returns |
| Type |
Description |
Type |
|
parseFrom(ByteBuffer data)
public static Type parseFrom(ByteBuffer data)
| Returns |
| Type |
Description |
Type |
|
parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
public static Type parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
| Returns |
| Type |
Description |
Type |
|
parser()
public static Parser<Type> parser()
Methods
equals(Object obj)
public boolean equals(Object obj)
| Parameter |
| Name |
Description |
obj |
Object
|
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 |
| Type |
Description |
Type |
The arrayElementType.
|
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;
getCode()
public TypeCode getCode()
Required. The TypeCode for this type.
.google.spanner.v1.TypeCode code = 1 [(.google.api.field_behavior) = REQUIRED];
| Returns |
| Type |
Description |
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 |
| Type |
Description |
int |
The enum numeric value on the wire for code.
|
getDefaultInstanceForType()
public Type getDefaultInstanceForType()
| Returns |
| Type |
Description |
Type |
|
getParserForType()
public Parser<Type> getParserForType()
Overrides
getProtoTypeFqn()
public String getProtoTypeFqn()
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 |
| Type |
Description |
String |
The protoTypeFqn.
|
getProtoTypeFqnBytes()
public ByteString getProtoTypeFqnBytes()
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 |
| Type |
Description |
ByteString |
The bytes for protoTypeFqn.
|
getSerializedSize()
public int getSerializedSize()
| Returns |
| Type |
Description |
int |
|
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 |
| Type |
Description |
StructType |
The structType.
|
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;
getTypeAnnotation()
public TypeAnnotationCode getTypeAnnotation()
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;
getTypeAnnotationValue()
public int getTypeAnnotationValue()
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 |
| Type |
Description |
int |
The enum numeric value on the wire for typeAnnotation.
|
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 |
| Type |
Description |
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 |
| Type |
Description |
boolean |
Whether the structType field is set.
|
hashCode()
| Returns |
| Type |
Description |
int |
|
Overrides
internalGetFieldAccessorTable()
protected GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
Overrides
isInitialized()
public final boolean isInitialized()
Overrides
newBuilderForType()
public Type.Builder newBuilderForType()
newBuilderForType(AbstractMessage.BuilderParent parent)
protected Type.Builder newBuilderForType(AbstractMessage.BuilderParent parent)
Overrides
toBuilder()
public Type.Builder toBuilder()
writeTo(CodedOutputStream output)
public void writeTo(CodedOutputStream output)
Overrides