Package com.google.spanner.v1
Interface SessionOrBuilder
- All Superinterfaces:
com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder
- All Known Implementing Classes:
Session,Session.Builder
public interface SessionOrBuilder
extends com.google.protobuf.MessageOrBuilder
-
Method Summary
Modifier and TypeMethodDescriptionbooleancontainsLabels(String key) The labels for the sessioncom.google.protobuf.TimestampOutput only.com.google.protobuf.TimestampOrBuilderOutput only.com.google.protobuf.TimestampOutput only.com.google.protobuf.TimestampOrBuilderOutput only.The database role which created this session.com.google.protobuf.ByteStringThe database role which created this session.Deprecated.intThe labels for the sessionThe labels for the sessiongetLabelsOrDefault(String key, String defaultValue) The labels for the sessiongetLabelsOrThrow(String key) The labels for the sessionbooleanOptional.getName()Output only.com.google.protobuf.ByteStringOutput only.booleanOutput only.booleanOutput only.Methods inherited from interface com.google.protobuf.MessageLiteOrBuilder
isInitializedMethods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getDefaultInstanceForType, getDescriptorForType, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Method Details
-
getName
String getName()Output only. The name of the session. This is always system-assigned.
string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];- Returns:
- The name.
-
getNameBytes
com.google.protobuf.ByteString getNameBytes()Output only. The name of the session. This is always system-assigned.
string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];- Returns:
- The bytes for name.
-
getLabelsCount
int getLabelsCount()The labels for the session. * Label keys must be between 1 and 63 characters long and must conform to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. * Label values must be between 0 and 63 characters long and must conform to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. * No more than 64 labels can be associated with a given session. See https://goo.gl/xmQnxf for more information on and examples of labels.map<string, string> labels = 2; -
containsLabels
The labels for the session. * Label keys must be between 1 and 63 characters long and must conform to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. * Label values must be between 0 and 63 characters long and must conform to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. * No more than 64 labels can be associated with a given session. See https://goo.gl/xmQnxf for more information on and examples of labels.map<string, string> labels = 2; -
getLabels
Deprecated.UsegetLabelsMap()instead. -
getLabelsMap
The labels for the session. * Label keys must be between 1 and 63 characters long and must conform to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. * Label values must be between 0 and 63 characters long and must conform to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. * No more than 64 labels can be associated with a given session. See https://goo.gl/xmQnxf for more information on and examples of labels.map<string, string> labels = 2; -
getLabelsOrDefault
The labels for the session. * Label keys must be between 1 and 63 characters long and must conform to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. * Label values must be between 0 and 63 characters long and must conform to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. * No more than 64 labels can be associated with a given session. See https://goo.gl/xmQnxf for more information on and examples of labels.map<string, string> labels = 2; -
getLabelsOrThrow
The labels for the session. * Label keys must be between 1 and 63 characters long and must conform to the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. * Label values must be between 0 and 63 characters long and must conform to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. * No more than 64 labels can be associated with a given session. See https://goo.gl/xmQnxf for more information on and examples of labels.map<string, string> labels = 2; -
hasCreateTime
boolean hasCreateTime()Output only. The timestamp when the session is created.
.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];- Returns:
- Whether the createTime field is set.
-
getCreateTime
com.google.protobuf.Timestamp getCreateTime()Output only. The timestamp when the session is created.
.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];- Returns:
- The createTime.
-
getCreateTimeOrBuilder
com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder()Output only. The timestamp when the session is created.
.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; -
hasApproximateLastUseTime
boolean hasApproximateLastUseTime()Output only. The approximate timestamp when the session is last used. It is typically earlier than the actual last use time.
.google.protobuf.Timestamp approximate_last_use_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];- Returns:
- Whether the approximateLastUseTime field is set.
-
getApproximateLastUseTime
com.google.protobuf.Timestamp getApproximateLastUseTime()Output only. The approximate timestamp when the session is last used. It is typically earlier than the actual last use time.
.google.protobuf.Timestamp approximate_last_use_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];- Returns:
- The approximateLastUseTime.
-
getApproximateLastUseTimeOrBuilder
com.google.protobuf.TimestampOrBuilder getApproximateLastUseTimeOrBuilder()Output only. The approximate timestamp when the session is last used. It is typically earlier than the actual last use time.
.google.protobuf.Timestamp approximate_last_use_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; -
getCreatorRole
String getCreatorRole()The database role which created this session.
string creator_role = 5;- Returns:
- The creatorRole.
-
getCreatorRoleBytes
com.google.protobuf.ByteString getCreatorRoleBytes()The database role which created this session.
string creator_role = 5;- Returns:
- The bytes for creatorRole.
-
getMultiplexed
boolean getMultiplexed()Optional. If true, specifies a multiplexed session. A multiplexed session may be used for multiple, concurrent read-only operations but can not be used for read-write transactions, partitioned reads, or partitioned queries. Multiplexed sessions can be created via [CreateSession][google.spanner.v1.Spanner.CreateSession] but not via [BatchCreateSessions][google.spanner.v1.Spanner.BatchCreateSessions]. Multiplexed sessions may not be deleted nor listed.
bool multiplexed = 6 [(.google.api.field_behavior) = OPTIONAL];- Returns:
- The multiplexed.
-