public final class KeyRecipe extends GeneratedMessage implements KeyRecipeOrBuilder
A KeyRecipe provides the metadata required to translate reads, mutations,
and queries into a byte array in "sortable string format" (ssformat)that can
be used with Ranges to route requests. Note that the client must tolerate
KeyRecipes that appear to be invalid, since the KeyRecipe format may
change over time. Requests with invalid KeyRecipes should be routed to a
default server.
Protobuf type google.spanner.v1.KeyRecipe
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
INDEX_NAME_FIELD_NUMBER
public static final int INDEX_NAME_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
|
OPERATION_UID_FIELD_NUMBER
public static final int OPERATION_UID_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
|
PART_FIELD_NUMBER
public static final int PART_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
|
TABLE_NAME_FIELD_NUMBER
public static final int TABLE_NAME_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
|
Static Methods
getDefaultInstance()
public static KeyRecipe getDefaultInstance()
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
newBuilder()
public static KeyRecipe.Builder newBuilder()
newBuilder(KeyRecipe prototype)
public static KeyRecipe.Builder newBuilder(KeyRecipe prototype)
| Parameter |
| Name |
Description |
prototype |
KeyRecipe
|
public static KeyRecipe parseDelimitedFrom(InputStream input)
public static KeyRecipe parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
parseFrom(byte[] data)
public static KeyRecipe parseFrom(byte[] data)
| Parameter |
| Name |
Description |
data |
byte[]
|
parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
public static KeyRecipe parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
parseFrom(ByteString data)
public static KeyRecipe parseFrom(ByteString data)
parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static KeyRecipe parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static KeyRecipe parseFrom(CodedInputStream input)
public static KeyRecipe parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public static KeyRecipe parseFrom(InputStream input)
public static KeyRecipe parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
parseFrom(ByteBuffer data)
public static KeyRecipe parseFrom(ByteBuffer data)
parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
public static KeyRecipe parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
parser()
public static Parser<KeyRecipe> parser()
Methods
equals(Object obj)
public boolean equals(Object obj)
| Parameter |
| Name |
Description |
obj |
Object
|
Overrides
getDefaultInstanceForType()
public KeyRecipe getDefaultInstanceForType()
getIndexName()
public String getIndexName()
An index name, matching the name from the database schema.
string index_name = 2;
| Returns |
| Type |
Description |
String |
The indexName.
|
getIndexNameBytes()
public ByteString getIndexNameBytes()
An index name, matching the name from the database schema.
string index_name = 2;
| Returns |
| Type |
Description |
ByteString |
The bytes for indexName.
|
getOperationUid()
public long getOperationUid()
The UID of a query, matching the UID from RoutingHint.
uint64 operation_uid = 3;
| Returns |
| Type |
Description |
long |
The operationUid.
|
getParserForType()
public Parser<KeyRecipe> getParserForType()
Overrides
getPart(int index)
public KeyRecipe.Part getPart(int index)
Parts are in the order they should appear in the encoded key.
repeated .google.spanner.v1.KeyRecipe.Part part = 4;
| Parameter |
| Name |
Description |
index |
int
|
getPartCount()
public int getPartCount()
Parts are in the order they should appear in the encoded key.
repeated .google.spanner.v1.KeyRecipe.Part part = 4;
| Returns |
| Type |
Description |
int |
|
getPartList()
public List<KeyRecipe.Part> getPartList()
Parts are in the order they should appear in the encoded key.
repeated .google.spanner.v1.KeyRecipe.Part part = 4;
getPartOrBuilder(int index)
public KeyRecipe.PartOrBuilder getPartOrBuilder(int index)
Parts are in the order they should appear in the encoded key.
repeated .google.spanner.v1.KeyRecipe.Part part = 4;
| Parameter |
| Name |
Description |
index |
int
|
getPartOrBuilderList()
public List<? extends KeyRecipe.PartOrBuilder> getPartOrBuilderList()
Parts are in the order they should appear in the encoded key.
repeated .google.spanner.v1.KeyRecipe.Part part = 4;
| Returns |
| Type |
Description |
List<? extends com.google.spanner.v1.KeyRecipe.PartOrBuilder> |
|
getSerializedSize()
public int getSerializedSize()
| Returns |
| Type |
Description |
int |
|
Overrides
getTableName()
public String getTableName()
A table name, matching the name from the database schema.
string table_name = 1;
| Returns |
| Type |
Description |
String |
The tableName.
|
getTableNameBytes()
public ByteString getTableNameBytes()
A table name, matching the name from the database schema.
string table_name = 1;
| Returns |
| Type |
Description |
ByteString |
The bytes for tableName.
|
getTargetCase()
public KeyRecipe.TargetCase getTargetCase()
hasIndexName()
public boolean hasIndexName()
An index name, matching the name from the database schema.
string index_name = 2;
| Returns |
| Type |
Description |
boolean |
Whether the indexName field is set.
|
hasOperationUid()
public boolean hasOperationUid()
The UID of a query, matching the UID from RoutingHint.
uint64 operation_uid = 3;
| Returns |
| Type |
Description |
boolean |
Whether the operationUid field is set.
|
hasTableName()
public boolean hasTableName()
A table name, matching the name from the database schema.
string table_name = 1;
| Returns |
| Type |
Description |
boolean |
Whether the tableName field is set.
|
hashCode()
| Returns |
| Type |
Description |
int |
|
Overrides
internalGetFieldAccessorTable()
protected GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
Overrides
isInitialized()
public final boolean isInitialized()
Overrides
newBuilderForType()
public KeyRecipe.Builder newBuilderForType()
newBuilderForType(AbstractMessage.BuilderParent parent)
protected KeyRecipe.Builder newBuilderForType(AbstractMessage.BuilderParent parent)
Overrides
toBuilder()
public KeyRecipe.Builder toBuilder()
writeTo(CodedOutputStream output)
public void writeTo(CodedOutputStream output)
Overrides