Package com.google.cloud.spanner.v1.stub
Class HttpJsonSpannerStub
- java.lang.Object
-
- com.google.cloud.spanner.v1.stub.SpannerStub
-
- com.google.cloud.spanner.v1.stub.HttpJsonSpannerStub
-
- All Implemented Interfaces:
com.google.api.gax.core.BackgroundResource
,AutoCloseable
@Generated("by gapic-generator-java") @BetaApi public class HttpJsonSpannerStub extends SpannerStub
REST stub implementation for the Spanner service API.This class is for advanced usage and reflects the underlying API directly.
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
HttpJsonSpannerStub(SpannerStubSettings settings, com.google.api.gax.rpc.ClientContext clientContext)
Constructs an instance of HttpJsonSpannerStub, using the given settings.protected
HttpJsonSpannerStub(SpannerStubSettings settings, com.google.api.gax.rpc.ClientContext clientContext, com.google.api.gax.httpjson.HttpJsonStubCallableFactory callableFactory)
Constructs an instance of HttpJsonSpannerStub, using the given settings.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
awaitTermination(long duration, TimeUnit unit)
com.google.api.gax.rpc.UnaryCallable<BatchCreateSessionsRequest,BatchCreateSessionsResponse>
batchCreateSessionsCallable()
com.google.api.gax.rpc.UnaryCallable<BeginTransactionRequest,Transaction>
beginTransactionCallable()
void
close()
com.google.api.gax.rpc.UnaryCallable<CommitRequest,CommitResponse>
commitCallable()
static HttpJsonSpannerStub
create(com.google.api.gax.rpc.ClientContext clientContext)
static HttpJsonSpannerStub
create(com.google.api.gax.rpc.ClientContext clientContext, com.google.api.gax.httpjson.HttpJsonStubCallableFactory callableFactory)
static HttpJsonSpannerStub
create(SpannerStubSettings settings)
com.google.api.gax.rpc.UnaryCallable<CreateSessionRequest,Session>
createSessionCallable()
com.google.api.gax.rpc.UnaryCallable<DeleteSessionRequest,com.google.protobuf.Empty>
deleteSessionCallable()
com.google.api.gax.rpc.UnaryCallable<ExecuteBatchDmlRequest,ExecuteBatchDmlResponse>
executeBatchDmlCallable()
com.google.api.gax.rpc.UnaryCallable<ExecuteSqlRequest,ResultSet>
executeSqlCallable()
com.google.api.gax.rpc.ServerStreamingCallable<ExecuteSqlRequest,PartialResultSet>
executeStreamingSqlCallable()
static List<com.google.api.gax.httpjson.ApiMethodDescriptor>
getMethodDescriptors()
com.google.api.gax.rpc.UnaryCallable<GetSessionRequest,Session>
getSessionCallable()
boolean
isShutdown()
boolean
isTerminated()
com.google.api.gax.rpc.UnaryCallable<ListSessionsRequest,ListSessionsResponse>
listSessionsCallable()
com.google.api.gax.rpc.UnaryCallable<ListSessionsRequest,SpannerClient.ListSessionsPagedResponse>
listSessionsPagedCallable()
com.google.api.gax.rpc.UnaryCallable<PartitionQueryRequest,PartitionResponse>
partitionQueryCallable()
com.google.api.gax.rpc.UnaryCallable<PartitionReadRequest,PartitionResponse>
partitionReadCallable()
com.google.api.gax.rpc.UnaryCallable<ReadRequest,ResultSet>
readCallable()
com.google.api.gax.rpc.UnaryCallable<RollbackRequest,com.google.protobuf.Empty>
rollbackCallable()
void
shutdown()
void
shutdownNow()
com.google.api.gax.rpc.ServerStreamingCallable<ReadRequest,PartialResultSet>
streamingReadCallable()
-
-
-
Constructor Detail
-
HttpJsonSpannerStub
protected HttpJsonSpannerStub(SpannerStubSettings settings, com.google.api.gax.rpc.ClientContext clientContext) throws IOException
Constructs an instance of HttpJsonSpannerStub, using the given settings. This is protected so that it is easy to make a subclass, but otherwise, the static factory methods should be preferred.- Throws:
IOException
-
HttpJsonSpannerStub
protected HttpJsonSpannerStub(SpannerStubSettings settings, com.google.api.gax.rpc.ClientContext clientContext, com.google.api.gax.httpjson.HttpJsonStubCallableFactory callableFactory) throws IOException
Constructs an instance of HttpJsonSpannerStub, using the given settings. This is protected so that it is easy to make a subclass, but otherwise, the static factory methods should be preferred.- Throws:
IOException
-
-
Method Detail
-
create
public static final HttpJsonSpannerStub create(SpannerStubSettings settings) throws IOException
- Throws:
IOException
-
create
public static final HttpJsonSpannerStub create(com.google.api.gax.rpc.ClientContext clientContext) throws IOException
- Throws:
IOException
-
create
public static final HttpJsonSpannerStub create(com.google.api.gax.rpc.ClientContext clientContext, com.google.api.gax.httpjson.HttpJsonStubCallableFactory callableFactory) throws IOException
- Throws:
IOException
-
getMethodDescriptors
@InternalApi public static List<com.google.api.gax.httpjson.ApiMethodDescriptor> getMethodDescriptors()
-
createSessionCallable
public com.google.api.gax.rpc.UnaryCallable<CreateSessionRequest,Session> createSessionCallable()
- Overrides:
createSessionCallable
in classSpannerStub
-
batchCreateSessionsCallable
public com.google.api.gax.rpc.UnaryCallable<BatchCreateSessionsRequest,BatchCreateSessionsResponse> batchCreateSessionsCallable()
- Overrides:
batchCreateSessionsCallable
in classSpannerStub
-
getSessionCallable
public com.google.api.gax.rpc.UnaryCallable<GetSessionRequest,Session> getSessionCallable()
- Overrides:
getSessionCallable
in classSpannerStub
-
listSessionsCallable
public com.google.api.gax.rpc.UnaryCallable<ListSessionsRequest,ListSessionsResponse> listSessionsCallable()
- Overrides:
listSessionsCallable
in classSpannerStub
-
listSessionsPagedCallable
public com.google.api.gax.rpc.UnaryCallable<ListSessionsRequest,SpannerClient.ListSessionsPagedResponse> listSessionsPagedCallable()
- Overrides:
listSessionsPagedCallable
in classSpannerStub
-
deleteSessionCallable
public com.google.api.gax.rpc.UnaryCallable<DeleteSessionRequest,com.google.protobuf.Empty> deleteSessionCallable()
- Overrides:
deleteSessionCallable
in classSpannerStub
-
executeSqlCallable
public com.google.api.gax.rpc.UnaryCallable<ExecuteSqlRequest,ResultSet> executeSqlCallable()
- Overrides:
executeSqlCallable
in classSpannerStub
-
executeStreamingSqlCallable
public com.google.api.gax.rpc.ServerStreamingCallable<ExecuteSqlRequest,PartialResultSet> executeStreamingSqlCallable()
- Overrides:
executeStreamingSqlCallable
in classSpannerStub
-
executeBatchDmlCallable
public com.google.api.gax.rpc.UnaryCallable<ExecuteBatchDmlRequest,ExecuteBatchDmlResponse> executeBatchDmlCallable()
- Overrides:
executeBatchDmlCallable
in classSpannerStub
-
readCallable
public com.google.api.gax.rpc.UnaryCallable<ReadRequest,ResultSet> readCallable()
- Overrides:
readCallable
in classSpannerStub
-
streamingReadCallable
public com.google.api.gax.rpc.ServerStreamingCallable<ReadRequest,PartialResultSet> streamingReadCallable()
- Overrides:
streamingReadCallable
in classSpannerStub
-
beginTransactionCallable
public com.google.api.gax.rpc.UnaryCallable<BeginTransactionRequest,Transaction> beginTransactionCallable()
- Overrides:
beginTransactionCallable
in classSpannerStub
-
commitCallable
public com.google.api.gax.rpc.UnaryCallable<CommitRequest,CommitResponse> commitCallable()
- Overrides:
commitCallable
in classSpannerStub
-
rollbackCallable
public com.google.api.gax.rpc.UnaryCallable<RollbackRequest,com.google.protobuf.Empty> rollbackCallable()
- Overrides:
rollbackCallable
in classSpannerStub
-
partitionQueryCallable
public com.google.api.gax.rpc.UnaryCallable<PartitionQueryRequest,PartitionResponse> partitionQueryCallable()
- Overrides:
partitionQueryCallable
in classSpannerStub
-
partitionReadCallable
public com.google.api.gax.rpc.UnaryCallable<PartitionReadRequest,PartitionResponse> partitionReadCallable()
- Overrides:
partitionReadCallable
in classSpannerStub
-
close
public final void close()
- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in classSpannerStub
-
shutdown
public void shutdown()
-
isShutdown
public boolean isShutdown()
-
isTerminated
public boolean isTerminated()
-
shutdownNow
public void shutdownNow()
-
awaitTermination
public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException
- Throws:
InterruptedException
-
-