Package com.google.spanner.v1
Class KeyRecipe.Builder
java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessageV3.Builder<KeyRecipe.Builder>
com.google.spanner.v1.KeyRecipe.Builder
- All Implemented Interfaces:
com.google.protobuf.Message.Builder,com.google.protobuf.MessageLite.Builder,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,KeyRecipeOrBuilder,Cloneable
- Enclosing class:
- KeyRecipe
public static final class KeyRecipe.Builder
extends com.google.protobuf.GeneratedMessageV3.Builder<KeyRecipe.Builder>
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 `Range`s to route requests. Note that the client *must* tolerate `KeyRecipe`s that appear to be invalid, since the `KeyRecipe` format may change over time. Requests with invalid `KeyRecipe`s should be routed to a default server.Protobuf type
google.spanner.v1.KeyRecipe-
Method Summary
Modifier and TypeMethodDescriptionaddAllPart(Iterable<? extends KeyRecipe.Part> values) Parts are in the order they should appear in the encoded key.addPart(int index, KeyRecipe.Part value) Parts are in the order they should appear in the encoded key.addPart(int index, KeyRecipe.Part.Builder builderForValue) Parts are in the order they should appear in the encoded key.addPart(KeyRecipe.Part value) Parts are in the order they should appear in the encoded key.addPart(KeyRecipe.Part.Builder builderForValue) Parts are in the order they should appear in the encoded key.Parts are in the order they should appear in the encoded key.addPartBuilder(int index) Parts are in the order they should appear in the encoded key.addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value) build()clear()clearField(com.google.protobuf.Descriptors.FieldDescriptor field) An index name, matching the name from the database schema.clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) The UID of a query, matching the UID from `RoutingHint`.Parts are in the order they should appear in the encoded key.A table name, matching the name from the database schema.clone()static final com.google.protobuf.Descriptors.Descriptorcom.google.protobuf.Descriptors.DescriptorAn index name, matching the name from the database schema.com.google.protobuf.ByteStringAn index name, matching the name from the database schema.longThe UID of a query, matching the UID from `RoutingHint`.getPart(int index) Parts are in the order they should appear in the encoded key.getPartBuilder(int index) Parts are in the order they should appear in the encoded key.Parts are in the order they should appear in the encoded key.intParts are in the order they should appear in the encoded key.Parts are in the order they should appear in the encoded key.getPartOrBuilder(int index) Parts are in the order they should appear in the encoded key.List<? extends KeyRecipe.PartOrBuilder>Parts are in the order they should appear in the encoded key.A table name, matching the name from the database schema.com.google.protobuf.ByteStringA table name, matching the name from the database schema.booleanAn index name, matching the name from the database schema.booleanThe UID of a query, matching the UID from `RoutingHint`.booleanA table name, matching the name from the database schema.protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTablefinal booleanmergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) mergeFrom(com.google.protobuf.Message other) final KeyRecipe.BuildermergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) removePart(int index) Parts are in the order they should appear in the encoded key.setIndexName(String value) An index name, matching the name from the database schema.setIndexNameBytes(com.google.protobuf.ByteString value) An index name, matching the name from the database schema.setOperationUid(long value) The UID of a query, matching the UID from `RoutingHint`.setPart(int index, KeyRecipe.Part value) Parts are in the order they should appear in the encoded key.setPart(int index, KeyRecipe.Part.Builder builderForValue) Parts are in the order they should appear in the encoded key.setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value) setTableName(String value) A table name, matching the name from the database schema.setTableNameBytes(com.google.protobuf.ByteString value) A table name, matching the name from the database schema.final KeyRecipe.BuildersetUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) Methods inherited from class com.google.protobuf.GeneratedMessageV3.Builder
getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, internalGetMutableMapField, internalGetMutableMapFieldReflection, isClean, markClean, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setUnknownFieldSetBuilder, setUnknownFieldsProto3Methods inherited from class com.google.protobuf.AbstractMessage.Builder
findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toStringMethods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageExceptionMethods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.protobuf.Message.Builder
mergeDelimitedFrom, mergeDelimitedFromMethods inherited from interface com.google.protobuf.MessageLite.Builder
mergeFromMethods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Method Details
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() -
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()- Specified by:
internalGetFieldAccessorTablein classcom.google.protobuf.GeneratedMessageV3.Builder<KeyRecipe.Builder>
-
clear
- Specified by:
clearin interfacecom.google.protobuf.Message.Builder- Specified by:
clearin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
clearin classcom.google.protobuf.GeneratedMessageV3.Builder<KeyRecipe.Builder>
-
getDescriptorForType
public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.Message.Builder- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.MessageOrBuilder- Overrides:
getDescriptorForTypein classcom.google.protobuf.GeneratedMessageV3.Builder<KeyRecipe.Builder>
-
getDefaultInstanceForType
- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageLiteOrBuilder- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageOrBuilder
-
build
- Specified by:
buildin interfacecom.google.protobuf.Message.Builder- Specified by:
buildin interfacecom.google.protobuf.MessageLite.Builder
-
buildPartial
- Specified by:
buildPartialin interfacecom.google.protobuf.Message.Builder- Specified by:
buildPartialin interfacecom.google.protobuf.MessageLite.Builder
-
clone
- Specified by:
clonein interfacecom.google.protobuf.Message.Builder- Specified by:
clonein interfacecom.google.protobuf.MessageLite.Builder- Overrides:
clonein classcom.google.protobuf.GeneratedMessageV3.Builder<KeyRecipe.Builder>
-
setField
public KeyRecipe.Builder setField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value) - Specified by:
setFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
setFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<KeyRecipe.Builder>
-
clearField
- Specified by:
clearFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
clearFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<KeyRecipe.Builder>
-
clearOneof
- Specified by:
clearOneofin interfacecom.google.protobuf.Message.Builder- Overrides:
clearOneofin classcom.google.protobuf.GeneratedMessageV3.Builder<KeyRecipe.Builder>
-
setRepeatedField
public KeyRecipe.Builder setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value) - Specified by:
setRepeatedFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
setRepeatedFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<KeyRecipe.Builder>
-
addRepeatedField
public KeyRecipe.Builder addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value) - Specified by:
addRepeatedFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
addRepeatedFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<KeyRecipe.Builder>
-
mergeFrom
- Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<KeyRecipe.Builder>
-
mergeFrom
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessageV3.Builder<KeyRecipe.Builder>
-
mergeFrom
public KeyRecipe.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Specified by:
mergeFromin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<KeyRecipe.Builder>- Throws:
IOException
-
getTargetCase
- Specified by:
getTargetCasein interfaceKeyRecipeOrBuilder
-
clearTarget
-
hasTableName
public boolean hasTableName()A table name, matching the name from the database schema.
string table_name = 1;- Specified by:
hasTableNamein interfaceKeyRecipeOrBuilder- Returns:
- Whether the tableName field is set.
-
getTableName
A table name, matching the name from the database schema.
string table_name = 1;- Specified by:
getTableNamein interfaceKeyRecipeOrBuilder- Returns:
- The tableName.
-
getTableNameBytes
public com.google.protobuf.ByteString getTableNameBytes()A table name, matching the name from the database schema.
string table_name = 1;- Specified by:
getTableNameBytesin interfaceKeyRecipeOrBuilder- Returns:
- The bytes for tableName.
-
setTableName
A table name, matching the name from the database schema.
string table_name = 1;- Parameters:
value- The tableName to set.- Returns:
- This builder for chaining.
-
clearTableName
A table name, matching the name from the database schema.
string table_name = 1;- Returns:
- This builder for chaining.
-
setTableNameBytes
A table name, matching the name from the database schema.
string table_name = 1;- Parameters:
value- The bytes for tableName to set.- Returns:
- This builder for chaining.
-
hasIndexName
public boolean hasIndexName()An index name, matching the name from the database schema.
string index_name = 2;- Specified by:
hasIndexNamein interfaceKeyRecipeOrBuilder- Returns:
- Whether the indexName field is set.
-
getIndexName
An index name, matching the name from the database schema.
string index_name = 2;- Specified by:
getIndexNamein interfaceKeyRecipeOrBuilder- Returns:
- The indexName.
-
getIndexNameBytes
public com.google.protobuf.ByteString getIndexNameBytes()An index name, matching the name from the database schema.
string index_name = 2;- Specified by:
getIndexNameBytesin interfaceKeyRecipeOrBuilder- Returns:
- The bytes for indexName.
-
setIndexName
An index name, matching the name from the database schema.
string index_name = 2;- Parameters:
value- The indexName to set.- Returns:
- This builder for chaining.
-
clearIndexName
An index name, matching the name from the database schema.
string index_name = 2;- Returns:
- This builder for chaining.
-
setIndexNameBytes
An index name, matching the name from the database schema.
string index_name = 2;- Parameters:
value- The bytes for indexName to set.- Returns:
- This builder for chaining.
-
hasOperationUid
public boolean hasOperationUid()The UID of a query, matching the UID from `RoutingHint`.
uint64 operation_uid = 3;- Specified by:
hasOperationUidin interfaceKeyRecipeOrBuilder- Returns:
- Whether the operationUid field is set.
-
getOperationUid
public long getOperationUid()The UID of a query, matching the UID from `RoutingHint`.
uint64 operation_uid = 3;- Specified by:
getOperationUidin interfaceKeyRecipeOrBuilder- Returns:
- The operationUid.
-
setOperationUid
The UID of a query, matching the UID from `RoutingHint`.
uint64 operation_uid = 3;- Parameters:
value- The operationUid to set.- Returns:
- This builder for chaining.
-
clearOperationUid
The UID of a query, matching the UID from `RoutingHint`.
uint64 operation_uid = 3;- Returns:
- This builder for chaining.
-
getPartList
Parts are in the order they should appear in the encoded key.
repeated .google.spanner.v1.KeyRecipe.Part part = 4;- Specified by:
getPartListin interfaceKeyRecipeOrBuilder
-
getPartCount
public int getPartCount()Parts are in the order they should appear in the encoded key.
repeated .google.spanner.v1.KeyRecipe.Part part = 4;- Specified by:
getPartCountin interfaceKeyRecipeOrBuilder
-
getPart
Parts are in the order they should appear in the encoded key.
repeated .google.spanner.v1.KeyRecipe.Part part = 4;- Specified by:
getPartin interfaceKeyRecipeOrBuilder
-
setPart
Parts are in the order they should appear in the encoded key.
repeated .google.spanner.v1.KeyRecipe.Part part = 4; -
setPart
Parts are in the order they should appear in the encoded key.
repeated .google.spanner.v1.KeyRecipe.Part part = 4; -
addPart
Parts are in the order they should appear in the encoded key.
repeated .google.spanner.v1.KeyRecipe.Part part = 4; -
addPart
Parts are in the order they should appear in the encoded key.
repeated .google.spanner.v1.KeyRecipe.Part part = 4; -
addPart
Parts are in the order they should appear in the encoded key.
repeated .google.spanner.v1.KeyRecipe.Part part = 4; -
addPart
Parts are in the order they should appear in the encoded key.
repeated .google.spanner.v1.KeyRecipe.Part part = 4; -
addAllPart
Parts are in the order they should appear in the encoded key.
repeated .google.spanner.v1.KeyRecipe.Part part = 4; -
clearPart
Parts are in the order they should appear in the encoded key.
repeated .google.spanner.v1.KeyRecipe.Part part = 4; -
removePart
Parts are in the order they should appear in the encoded key.
repeated .google.spanner.v1.KeyRecipe.Part part = 4; -
getPartBuilder
Parts are in the order they should appear in the encoded key.
repeated .google.spanner.v1.KeyRecipe.Part part = 4; -
getPartOrBuilder
Parts are in the order they should appear in the encoded key.
repeated .google.spanner.v1.KeyRecipe.Part part = 4;- Specified by:
getPartOrBuilderin interfaceKeyRecipeOrBuilder
-
getPartOrBuilderList
Parts are in the order they should appear in the encoded key.
repeated .google.spanner.v1.KeyRecipe.Part part = 4;- Specified by:
getPartOrBuilderListin interfaceKeyRecipeOrBuilder
-
addPartBuilder
Parts are in the order they should appear in the encoded key.
repeated .google.spanner.v1.KeyRecipe.Part part = 4; -
addPartBuilder
Parts are in the order they should appear in the encoded key.
repeated .google.spanner.v1.KeyRecipe.Part part = 4; -
getPartBuilderList
Parts are in the order they should appear in the encoded key.
repeated .google.spanner.v1.KeyRecipe.Part part = 4; -
setUnknownFields
- Specified by:
setUnknownFieldsin interfacecom.google.protobuf.Message.Builder- Overrides:
setUnknownFieldsin classcom.google.protobuf.GeneratedMessageV3.Builder<KeyRecipe.Builder>
-
mergeUnknownFields
public final KeyRecipe.Builder mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) - Specified by:
mergeUnknownFieldsin interfacecom.google.protobuf.Message.Builder- Overrides:
mergeUnknownFieldsin classcom.google.protobuf.GeneratedMessageV3.Builder<KeyRecipe.Builder>
-