Package com.google.spanner.v1
Enum Tablet.Role
- All Implemented Interfaces:
com.google.protobuf.Internal.EnumLite,com.google.protobuf.ProtocolMessageEnum,Serializable,Comparable<Tablet.Role>
- Enclosing class:
- Tablet
public static enum Tablet.Role
extends Enum<Tablet.Role>
implements com.google.protobuf.ProtocolMessageEnum
Indicates the role of the tablet.Protobuf enum
google.spanner.v1.Tablet.Role-
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionThe tablet can only perform reads.The tablet can perform reads and (if elected leader) writes.Not specified. -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intThe tablet can only perform reads.static final intThe tablet can perform reads and (if elected leader) writes.static final intNot specified. -
Method Summary
Modifier and TypeMethodDescriptionstatic Tablet.RoleforNumber(int value) static final com.google.protobuf.Descriptors.EnumDescriptorfinal com.google.protobuf.Descriptors.EnumDescriptorfinal intfinal com.google.protobuf.Descriptors.EnumValueDescriptorstatic com.google.protobuf.Internal.EnumLiteMap<Tablet.Role>static Tablet.RolevalueOf(int value) Deprecated.static Tablet.RolevalueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) Returns the enum constant of this type with the specified name.static Tablet.RoleReturns the enum constant of this type with the specified name.static Tablet.Role[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
Enum Constant Details
-
ROLE_UNSPECIFIED
Not specified.
ROLE_UNSPECIFIED = 0; -
READ_WRITE
The tablet can perform reads and (if elected leader) writes.
READ_WRITE = 1; -
READ_ONLY
The tablet can only perform reads.
READ_ONLY = 2; -
UNRECOGNIZED
-
-
Field Details
-
ROLE_UNSPECIFIED_VALUE
public static final int ROLE_UNSPECIFIED_VALUENot specified.
ROLE_UNSPECIFIED = 0;- See Also:
-
READ_WRITE_VALUE
public static final int READ_WRITE_VALUEThe tablet can perform reads and (if elected leader) writes.
READ_WRITE = 1;- See Also:
-
READ_ONLY_VALUE
public static final int READ_ONLY_VALUEThe tablet can only perform reads.
READ_ONLY = 2;- See Also:
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum type has no constant with the specified nameNullPointerException- if the argument is null
-
getNumber
public final int getNumber()- Specified by:
getNumberin interfacecom.google.protobuf.Internal.EnumLite- Specified by:
getNumberin interfacecom.google.protobuf.ProtocolMessageEnum
-
valueOf
Deprecated.Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
value- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum type has no constant with the specified nameNullPointerException- if the argument is null
-
forNumber
- Parameters:
value- The numeric wire value of the corresponding enum entry.- Returns:
- The enum associated with the given numeric wire value.
-
internalGetValueMap
-
getValueDescriptor
public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor()- Specified by:
getValueDescriptorin interfacecom.google.protobuf.ProtocolMessageEnum
-
getDescriptorForType
public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType()- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.ProtocolMessageEnum
-
getDescriptor
public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() -
valueOf
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
desc- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum type has no constant with the specified nameNullPointerException- if the argument is null
-