Class KeyRecipe.Part (6.107.0)

public static final class KeyRecipe.Part extends GeneratedMessageV3 implements KeyRecipe.PartOrBuilder

An ssformat key is composed of a sequence of tag numbers and key column values. Part represents a single tag or key column value.

Protobuf type google.spanner.v1.KeyRecipe.Part

Static Fields

IDENTIFIER_FIELD_NUMBER

public static final int IDENTIFIER_FIELD_NUMBER
Field Value
Type Description
int

NULL_ORDER_FIELD_NUMBER

public static final int NULL_ORDER_FIELD_NUMBER
Field Value
Type Description
int

ORDER_FIELD_NUMBER

public static final int ORDER_FIELD_NUMBER
Field Value
Type Description
int

RANDOM_FIELD_NUMBER

public static final int RANDOM_FIELD_NUMBER
Field Value
Type Description
int

STRUCT_IDENTIFIERS_FIELD_NUMBER

public static final int STRUCT_IDENTIFIERS_FIELD_NUMBER
Field Value
Type Description
int

TAG_FIELD_NUMBER

public static final int TAG_FIELD_NUMBER
Field Value
Type Description
int

TYPE_FIELD_NUMBER

public static final int TYPE_FIELD_NUMBER
Field Value
Type Description
int

VALUE_FIELD_NUMBER

public static final int VALUE_FIELD_NUMBER
Field Value
Type Description
int

Static Methods

getDefaultInstance()

public static KeyRecipe.Part getDefaultInstance()
Returns
Type Description
KeyRecipe.Part

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

newBuilder()

public static KeyRecipe.Part.Builder newBuilder()
Returns
Type Description
KeyRecipe.Part.Builder

newBuilder(KeyRecipe.Part prototype)

public static KeyRecipe.Part.Builder newBuilder(KeyRecipe.Part prototype)
Parameter
Name Description
prototype KeyRecipe.Part
Returns
Type Description
KeyRecipe.Part.Builder

parseDelimitedFrom(InputStream input)

public static KeyRecipe.Part parseDelimitedFrom(InputStream input)
Parameter
Name Description
input InputStream
Returns
Type Description
KeyRecipe.Part
Exceptions
Type Description
IOException

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static KeyRecipe.Part parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input InputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
KeyRecipe.Part
Exceptions
Type Description
IOException

parseFrom(byte[] data)

public static KeyRecipe.Part parseFrom(byte[] data)
Parameter
Name Description
data byte[]
Returns
Type Description
KeyRecipe.Part
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

public static KeyRecipe.Part parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
data byte[]
extensionRegistry ExtensionRegistryLite
Returns
Type Description
KeyRecipe.Part
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(ByteString data)

public static KeyRecipe.Part parseFrom(ByteString data)
Parameter
Name Description
data ByteString
Returns
Type Description
KeyRecipe.Part
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

public static KeyRecipe.Part parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
data ByteString
extensionRegistry ExtensionRegistryLite
Returns
Type Description
KeyRecipe.Part
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(CodedInputStream input)

public static KeyRecipe.Part parseFrom(CodedInputStream input)
Parameter
Name Description
input CodedInputStream
Returns
Type Description
KeyRecipe.Part
Exceptions
Type Description
IOException

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public static KeyRecipe.Part parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
KeyRecipe.Part
Exceptions
Type Description
IOException

parseFrom(InputStream input)

public static KeyRecipe.Part parseFrom(InputStream input)
Parameter
Name Description
input InputStream
Returns
Type Description
KeyRecipe.Part
Exceptions
Type Description
IOException

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static KeyRecipe.Part parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input InputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
KeyRecipe.Part
Exceptions
Type Description
IOException

parseFrom(ByteBuffer data)

public static KeyRecipe.Part parseFrom(ByteBuffer data)
Parameter
Name Description
data ByteBuffer
Returns
Type Description
KeyRecipe.Part
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

public static KeyRecipe.Part parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
data ByteBuffer
extensionRegistry ExtensionRegistryLite
Returns
Type Description
KeyRecipe.Part
Exceptions
Type Description
InvalidProtocolBufferException

parser()

public static Parser<KeyRecipe.Part> parser()
Returns
Type Description
Parser<Part>

Methods

equals(Object obj)

public boolean equals(Object obj)
Parameter
Name Description
obj Object
Returns
Type Description
boolean
Overrides

getDefaultInstanceForType()

public KeyRecipe.Part getDefaultInstanceForType()
Returns
Type Description
KeyRecipe.Part

getIdentifier()

public String getIdentifier()

identifier is the name of the column or query parameter.

string identifier = 5;

Returns
Type Description
String

The identifier.

getIdentifierBytes()

public ByteString getIdentifierBytes()

identifier is the name of the column or query parameter.

string identifier = 5;

Returns
Type Description
ByteString

The bytes for identifier.

getNullOrder()

public KeyRecipe.Part.NullOrder getNullOrder()

How NULLs are represented in the encoded key part. Only present if tag is zero.

.google.spanner.v1.KeyRecipe.Part.NullOrder null_order = 3;

Returns
Type Description
KeyRecipe.Part.NullOrder

The nullOrder.

getNullOrderValue()

public int getNullOrderValue()

How NULLs are represented in the encoded key part. Only present if tag is zero.

.google.spanner.v1.KeyRecipe.Part.NullOrder null_order = 3;

Returns
Type Description
int

The enum numeric value on the wire for nullOrder.

getOrder()

public KeyRecipe.Part.Order getOrder()

Whether the key column is sorted ascending or descending. Only present if tag is zero.

.google.spanner.v1.KeyRecipe.Part.Order order = 2;

Returns
Type Description
KeyRecipe.Part.Order

The order.

getOrderValue()

public int getOrderValue()

Whether the key column is sorted ascending or descending. Only present if tag is zero.

.google.spanner.v1.KeyRecipe.Part.Order order = 2;

Returns
Type Description
int

The enum numeric value on the wire for order.

getParserForType()

public Parser<KeyRecipe.Part> getParserForType()
Returns
Type Description
Parser<Part>
Overrides

getRandom()

public boolean getRandom()

If true, the client is responsible to fill in the value randomly. It's relevant only for the INT64 type.

bool random = 8;

Returns
Type Description
boolean

The random.

getSerializedSize()

public int getSerializedSize()
Returns
Type Description
int
Overrides

getStructIdentifiers(int index)

public int getStructIdentifiers(int index)

It is a repeated field to support fetching key columns from nested structs, such as STRUCT query parameters.

repeated int32 struct_identifiers = 7;

Parameter
Name Description
index int

The index of the element to return.

Returns
Type Description
int

The structIdentifiers at the given index.

getStructIdentifiersCount()

public int getStructIdentifiersCount()

It is a repeated field to support fetching key columns from nested structs, such as STRUCT query parameters.

repeated int32 struct_identifiers = 7;

Returns
Type Description
int

The count of structIdentifiers.

getStructIdentifiersList()

public List<Integer> getStructIdentifiersList()

It is a repeated field to support fetching key columns from nested structs, such as STRUCT query parameters.

repeated int32 struct_identifiers = 7;

Returns
Type Description
List<Integer>

A list containing the structIdentifiers.

getTag()

public int getTag()

If non-zero, tag is the only field present in this Part. The part is encoded by appending tag to the ssformat key.

uint32 tag = 1;

Returns
Type Description
int

The tag.

getType()

public Type getType()

The type of the key part. Only present if tag is zero.

.google.spanner.v1.Type type = 4;

Returns
Type Description
Type

The type.

getTypeOrBuilder()

public TypeOrBuilder getTypeOrBuilder()

The type of the key part. Only present if tag is zero.

.google.spanner.v1.Type type = 4;

Returns
Type Description
TypeOrBuilder

getValue()

public Value getValue()

The constant value of the key part. It is present when query uses a constant as a part of the key.

.google.protobuf.Value value = 6;

Returns
Type Description
Value

The value.

getValueOrBuilder()

public ValueOrBuilder getValueOrBuilder()

The constant value of the key part. It is present when query uses a constant as a part of the key.

.google.protobuf.Value value = 6;

Returns
Type Description
ValueOrBuilder

getValueTypeCase()

public KeyRecipe.Part.ValueTypeCase getValueTypeCase()
Returns
Type Description
KeyRecipe.Part.ValueTypeCase

hasIdentifier()

public boolean hasIdentifier()

identifier is the name of the column or query parameter.

string identifier = 5;

Returns
Type Description
boolean

Whether the identifier field is set.

hasRandom()

public boolean hasRandom()

If true, the client is responsible to fill in the value randomly. It's relevant only for the INT64 type.

bool random = 8;

Returns
Type Description
boolean

Whether the random field is set.

hasType()

public boolean hasType()

The type of the key part. Only present if tag is zero.

.google.spanner.v1.Type type = 4;

Returns
Type Description
boolean

Whether the type field is set.

hasValue()

public boolean hasValue()

The constant value of the key part. It is present when query uses a constant as a part of the key.

.google.protobuf.Value value = 6;

Returns
Type Description
boolean

Whether the value field is set.

hashCode()

public int hashCode()
Returns
Type Description
int
Overrides

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

newBuilderForType()

public KeyRecipe.Part.Builder newBuilderForType()
Returns
Type Description
KeyRecipe.Part.Builder

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

protected KeyRecipe.Part.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
Name Description
parent BuilderParent
Returns
Type Description
KeyRecipe.Part.Builder
Overrides

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
Name Description
unused UnusedPrivateParameter
Returns
Type Description
Object
Overrides

toBuilder()

public KeyRecipe.Part.Builder toBuilder()
Returns
Type Description
KeyRecipe.Part.Builder

writeTo(CodedOutputStream output)

public void writeTo(CodedOutputStream output)
Parameter
Name Description
output CodedOutputStream
Overrides
Exceptions
Type Description
IOException