All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.google.cloud.securityposture.v1.stub.GrpcSecurityPostureStub Maven / Gradle / Ivy

Go to download

Security Posture API Security Posture is a comprehensive framework of policy sets that empowers organizations to define, assess early, deploy, and monitor their security measures in a unified way and helps simplify governance and reduces administrative toil.

There is a newer version: 0.19.0
Show newest version
/*
 * Copyright 2024 Google LLC
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      https://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package com.google.cloud.securityposture.v1.stub;

import static com.google.cloud.securityposture.v1.SecurityPostureClient.ListLocationsPagedResponse;
import static com.google.cloud.securityposture.v1.SecurityPostureClient.ListPostureDeploymentsPagedResponse;
import static com.google.cloud.securityposture.v1.SecurityPostureClient.ListPostureRevisionsPagedResponse;
import static com.google.cloud.securityposture.v1.SecurityPostureClient.ListPostureTemplatesPagedResponse;
import static com.google.cloud.securityposture.v1.SecurityPostureClient.ListPosturesPagedResponse;

import com.google.api.gax.core.BackgroundResource;
import com.google.api.gax.core.BackgroundResourceAggregation;
import com.google.api.gax.grpc.GrpcCallSettings;
import com.google.api.gax.grpc.GrpcStubCallableFactory;
import com.google.api.gax.rpc.ClientContext;
import com.google.api.gax.rpc.OperationCallable;
import com.google.api.gax.rpc.RequestParamsBuilder;
import com.google.api.gax.rpc.UnaryCallable;
import com.google.cloud.location.GetLocationRequest;
import com.google.cloud.location.ListLocationsRequest;
import com.google.cloud.location.ListLocationsResponse;
import com.google.cloud.location.Location;
import com.google.cloud.securityposture.v1.CreatePostureDeploymentRequest;
import com.google.cloud.securityposture.v1.CreatePostureRequest;
import com.google.cloud.securityposture.v1.DeletePostureDeploymentRequest;
import com.google.cloud.securityposture.v1.DeletePostureRequest;
import com.google.cloud.securityposture.v1.ExtractPostureRequest;
import com.google.cloud.securityposture.v1.GetPostureDeploymentRequest;
import com.google.cloud.securityposture.v1.GetPostureRequest;
import com.google.cloud.securityposture.v1.GetPostureTemplateRequest;
import com.google.cloud.securityposture.v1.ListPostureDeploymentsRequest;
import com.google.cloud.securityposture.v1.ListPostureDeploymentsResponse;
import com.google.cloud.securityposture.v1.ListPostureRevisionsRequest;
import com.google.cloud.securityposture.v1.ListPostureRevisionsResponse;
import com.google.cloud.securityposture.v1.ListPostureTemplatesRequest;
import com.google.cloud.securityposture.v1.ListPostureTemplatesResponse;
import com.google.cloud.securityposture.v1.ListPosturesRequest;
import com.google.cloud.securityposture.v1.ListPosturesResponse;
import com.google.cloud.securityposture.v1.OperationMetadata;
import com.google.cloud.securityposture.v1.Posture;
import com.google.cloud.securityposture.v1.PostureDeployment;
import com.google.cloud.securityposture.v1.PostureTemplate;
import com.google.cloud.securityposture.v1.UpdatePostureDeploymentRequest;
import com.google.cloud.securityposture.v1.UpdatePostureRequest;
import com.google.longrunning.Operation;
import com.google.longrunning.stub.GrpcOperationsStub;
import com.google.protobuf.Empty;
import io.grpc.MethodDescriptor;
import io.grpc.protobuf.ProtoUtils;
import java.io.IOException;
import java.util.concurrent.TimeUnit;
import javax.annotation.Generated;

// AUTO-GENERATED DOCUMENTATION AND CLASS.
/**
 * gRPC stub implementation for the SecurityPosture service API.
 *
 * 

This class is for advanced usage and reflects the underlying API directly. */ @Generated("by gapic-generator-java") public class GrpcSecurityPostureStub extends SecurityPostureStub { private static final MethodDescriptor listPosturesMethodDescriptor = MethodDescriptor.newBuilder() .setType(MethodDescriptor.MethodType.UNARY) .setFullMethodName("google.cloud.securityposture.v1.SecurityPosture/ListPostures") .setRequestMarshaller(ProtoUtils.marshaller(ListPosturesRequest.getDefaultInstance())) .setResponseMarshaller( ProtoUtils.marshaller(ListPosturesResponse.getDefaultInstance())) .build(); private static final MethodDescriptor listPostureRevisionsMethodDescriptor = MethodDescriptor.newBuilder() .setType(MethodDescriptor.MethodType.UNARY) .setFullMethodName( "google.cloud.securityposture.v1.SecurityPosture/ListPostureRevisions") .setRequestMarshaller( ProtoUtils.marshaller(ListPostureRevisionsRequest.getDefaultInstance())) .setResponseMarshaller( ProtoUtils.marshaller(ListPostureRevisionsResponse.getDefaultInstance())) .build(); private static final MethodDescriptor getPostureMethodDescriptor = MethodDescriptor.newBuilder() .setType(MethodDescriptor.MethodType.UNARY) .setFullMethodName("google.cloud.securityposture.v1.SecurityPosture/GetPosture") .setRequestMarshaller(ProtoUtils.marshaller(GetPostureRequest.getDefaultInstance())) .setResponseMarshaller(ProtoUtils.marshaller(Posture.getDefaultInstance())) .build(); private static final MethodDescriptor createPostureMethodDescriptor = MethodDescriptor.newBuilder() .setType(MethodDescriptor.MethodType.UNARY) .setFullMethodName("google.cloud.securityposture.v1.SecurityPosture/CreatePosture") .setRequestMarshaller( ProtoUtils.marshaller(CreatePostureRequest.getDefaultInstance())) .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) .build(); private static final MethodDescriptor updatePostureMethodDescriptor = MethodDescriptor.newBuilder() .setType(MethodDescriptor.MethodType.UNARY) .setFullMethodName("google.cloud.securityposture.v1.SecurityPosture/UpdatePosture") .setRequestMarshaller( ProtoUtils.marshaller(UpdatePostureRequest.getDefaultInstance())) .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) .build(); private static final MethodDescriptor deletePostureMethodDescriptor = MethodDescriptor.newBuilder() .setType(MethodDescriptor.MethodType.UNARY) .setFullMethodName("google.cloud.securityposture.v1.SecurityPosture/DeletePosture") .setRequestMarshaller( ProtoUtils.marshaller(DeletePostureRequest.getDefaultInstance())) .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) .build(); private static final MethodDescriptor extractPostureMethodDescriptor = MethodDescriptor.newBuilder() .setType(MethodDescriptor.MethodType.UNARY) .setFullMethodName("google.cloud.securityposture.v1.SecurityPosture/ExtractPosture") .setRequestMarshaller( ProtoUtils.marshaller(ExtractPostureRequest.getDefaultInstance())) .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) .build(); private static final MethodDescriptor< ListPostureDeploymentsRequest, ListPostureDeploymentsResponse> listPostureDeploymentsMethodDescriptor = MethodDescriptor .newBuilder() .setType(MethodDescriptor.MethodType.UNARY) .setFullMethodName( "google.cloud.securityposture.v1.SecurityPosture/ListPostureDeployments") .setRequestMarshaller( ProtoUtils.marshaller(ListPostureDeploymentsRequest.getDefaultInstance())) .setResponseMarshaller( ProtoUtils.marshaller(ListPostureDeploymentsResponse.getDefaultInstance())) .build(); private static final MethodDescriptor getPostureDeploymentMethodDescriptor = MethodDescriptor.newBuilder() .setType(MethodDescriptor.MethodType.UNARY) .setFullMethodName( "google.cloud.securityposture.v1.SecurityPosture/GetPostureDeployment") .setRequestMarshaller( ProtoUtils.marshaller(GetPostureDeploymentRequest.getDefaultInstance())) .setResponseMarshaller(ProtoUtils.marshaller(PostureDeployment.getDefaultInstance())) .build(); private static final MethodDescriptor createPostureDeploymentMethodDescriptor = MethodDescriptor.newBuilder() .setType(MethodDescriptor.MethodType.UNARY) .setFullMethodName( "google.cloud.securityposture.v1.SecurityPosture/CreatePostureDeployment") .setRequestMarshaller( ProtoUtils.marshaller(CreatePostureDeploymentRequest.getDefaultInstance())) .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) .build(); private static final MethodDescriptor updatePostureDeploymentMethodDescriptor = MethodDescriptor.newBuilder() .setType(MethodDescriptor.MethodType.UNARY) .setFullMethodName( "google.cloud.securityposture.v1.SecurityPosture/UpdatePostureDeployment") .setRequestMarshaller( ProtoUtils.marshaller(UpdatePostureDeploymentRequest.getDefaultInstance())) .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) .build(); private static final MethodDescriptor deletePostureDeploymentMethodDescriptor = MethodDescriptor.newBuilder() .setType(MethodDescriptor.MethodType.UNARY) .setFullMethodName( "google.cloud.securityposture.v1.SecurityPosture/DeletePostureDeployment") .setRequestMarshaller( ProtoUtils.marshaller(DeletePostureDeploymentRequest.getDefaultInstance())) .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) .build(); private static final MethodDescriptor listPostureTemplatesMethodDescriptor = MethodDescriptor.newBuilder() .setType(MethodDescriptor.MethodType.UNARY) .setFullMethodName( "google.cloud.securityposture.v1.SecurityPosture/ListPostureTemplates") .setRequestMarshaller( ProtoUtils.marshaller(ListPostureTemplatesRequest.getDefaultInstance())) .setResponseMarshaller( ProtoUtils.marshaller(ListPostureTemplatesResponse.getDefaultInstance())) .build(); private static final MethodDescriptor getPostureTemplateMethodDescriptor = MethodDescriptor.newBuilder() .setType(MethodDescriptor.MethodType.UNARY) .setFullMethodName( "google.cloud.securityposture.v1.SecurityPosture/GetPostureTemplate") .setRequestMarshaller( ProtoUtils.marshaller(GetPostureTemplateRequest.getDefaultInstance())) .setResponseMarshaller(ProtoUtils.marshaller(PostureTemplate.getDefaultInstance())) .build(); private static final MethodDescriptor listLocationsMethodDescriptor = MethodDescriptor.newBuilder() .setType(MethodDescriptor.MethodType.UNARY) .setFullMethodName("google.cloud.location.Locations/ListLocations") .setRequestMarshaller( ProtoUtils.marshaller(ListLocationsRequest.getDefaultInstance())) .setResponseMarshaller( ProtoUtils.marshaller(ListLocationsResponse.getDefaultInstance())) .build(); private static final MethodDescriptor getLocationMethodDescriptor = MethodDescriptor.newBuilder() .setType(MethodDescriptor.MethodType.UNARY) .setFullMethodName("google.cloud.location.Locations/GetLocation") .setRequestMarshaller(ProtoUtils.marshaller(GetLocationRequest.getDefaultInstance())) .setResponseMarshaller(ProtoUtils.marshaller(Location.getDefaultInstance())) .build(); private final UnaryCallable listPosturesCallable; private final UnaryCallable listPosturesPagedCallable; private final UnaryCallable listPostureRevisionsCallable; private final UnaryCallable listPostureRevisionsPagedCallable; private final UnaryCallable getPostureCallable; private final UnaryCallable createPostureCallable; private final OperationCallable createPostureOperationCallable; private final UnaryCallable updatePostureCallable; private final OperationCallable updatePostureOperationCallable; private final UnaryCallable deletePostureCallable; private final OperationCallable deletePostureOperationCallable; private final UnaryCallable extractPostureCallable; private final OperationCallable extractPostureOperationCallable; private final UnaryCallable listPostureDeploymentsCallable; private final UnaryCallable listPostureDeploymentsPagedCallable; private final UnaryCallable getPostureDeploymentCallable; private final UnaryCallable createPostureDeploymentCallable; private final OperationCallable< CreatePostureDeploymentRequest, PostureDeployment, OperationMetadata> createPostureDeploymentOperationCallable; private final UnaryCallable updatePostureDeploymentCallable; private final OperationCallable< UpdatePostureDeploymentRequest, PostureDeployment, OperationMetadata> updatePostureDeploymentOperationCallable; private final UnaryCallable deletePostureDeploymentCallable; private final OperationCallable deletePostureDeploymentOperationCallable; private final UnaryCallable listPostureTemplatesCallable; private final UnaryCallable listPostureTemplatesPagedCallable; private final UnaryCallable getPostureTemplateCallable; private final UnaryCallable listLocationsCallable; private final UnaryCallable listLocationsPagedCallable; private final UnaryCallable getLocationCallable; private final BackgroundResource backgroundResources; private final GrpcOperationsStub operationsStub; private final GrpcStubCallableFactory callableFactory; public static final GrpcSecurityPostureStub create(SecurityPostureStubSettings settings) throws IOException { return new GrpcSecurityPostureStub(settings, ClientContext.create(settings)); } public static final GrpcSecurityPostureStub create(ClientContext clientContext) throws IOException { return new GrpcSecurityPostureStub( SecurityPostureStubSettings.newBuilder().build(), clientContext); } public static final GrpcSecurityPostureStub create( ClientContext clientContext, GrpcStubCallableFactory callableFactory) throws IOException { return new GrpcSecurityPostureStub( SecurityPostureStubSettings.newBuilder().build(), clientContext, callableFactory); } /** * Constructs an instance of GrpcSecurityPostureStub, 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. */ protected GrpcSecurityPostureStub( SecurityPostureStubSettings settings, ClientContext clientContext) throws IOException { this(settings, clientContext, new GrpcSecurityPostureCallableFactory()); } /** * Constructs an instance of GrpcSecurityPostureStub, 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. */ protected GrpcSecurityPostureStub( SecurityPostureStubSettings settings, ClientContext clientContext, GrpcStubCallableFactory callableFactory) throws IOException { this.callableFactory = callableFactory; this.operationsStub = GrpcOperationsStub.create(clientContext, callableFactory); GrpcCallSettings listPosturesTransportSettings = GrpcCallSettings.newBuilder() .setMethodDescriptor(listPosturesMethodDescriptor) .setParamsExtractor( request -> { RequestParamsBuilder builder = RequestParamsBuilder.create(); builder.add("parent", String.valueOf(request.getParent())); return builder.build(); }) .build(); GrpcCallSettings listPostureRevisionsTransportSettings = GrpcCallSettings.newBuilder() .setMethodDescriptor(listPostureRevisionsMethodDescriptor) .setParamsExtractor( request -> { RequestParamsBuilder builder = RequestParamsBuilder.create(); builder.add("name", String.valueOf(request.getName())); return builder.build(); }) .build(); GrpcCallSettings getPostureTransportSettings = GrpcCallSettings.newBuilder() .setMethodDescriptor(getPostureMethodDescriptor) .setParamsExtractor( request -> { RequestParamsBuilder builder = RequestParamsBuilder.create(); builder.add("name", String.valueOf(request.getName())); return builder.build(); }) .build(); GrpcCallSettings createPostureTransportSettings = GrpcCallSettings.newBuilder() .setMethodDescriptor(createPostureMethodDescriptor) .setParamsExtractor( request -> { RequestParamsBuilder builder = RequestParamsBuilder.create(); builder.add("parent", String.valueOf(request.getParent())); return builder.build(); }) .build(); GrpcCallSettings updatePostureTransportSettings = GrpcCallSettings.newBuilder() .setMethodDescriptor(updatePostureMethodDescriptor) .setParamsExtractor( request -> { RequestParamsBuilder builder = RequestParamsBuilder.create(); builder.add("posture.name", String.valueOf(request.getPosture().getName())); return builder.build(); }) .build(); GrpcCallSettings deletePostureTransportSettings = GrpcCallSettings.newBuilder() .setMethodDescriptor(deletePostureMethodDescriptor) .setParamsExtractor( request -> { RequestParamsBuilder builder = RequestParamsBuilder.create(); builder.add("name", String.valueOf(request.getName())); return builder.build(); }) .build(); GrpcCallSettings extractPostureTransportSettings = GrpcCallSettings.newBuilder() .setMethodDescriptor(extractPostureMethodDescriptor) .setParamsExtractor( request -> { RequestParamsBuilder builder = RequestParamsBuilder.create(); builder.add("parent", String.valueOf(request.getParent())); return builder.build(); }) .build(); GrpcCallSettings listPostureDeploymentsTransportSettings = GrpcCallSettings .newBuilder() .setMethodDescriptor(listPostureDeploymentsMethodDescriptor) .setParamsExtractor( request -> { RequestParamsBuilder builder = RequestParamsBuilder.create(); builder.add("parent", String.valueOf(request.getParent())); return builder.build(); }) .build(); GrpcCallSettings getPostureDeploymentTransportSettings = GrpcCallSettings.newBuilder() .setMethodDescriptor(getPostureDeploymentMethodDescriptor) .setParamsExtractor( request -> { RequestParamsBuilder builder = RequestParamsBuilder.create(); builder.add("name", String.valueOf(request.getName())); return builder.build(); }) .build(); GrpcCallSettings createPostureDeploymentTransportSettings = GrpcCallSettings.newBuilder() .setMethodDescriptor(createPostureDeploymentMethodDescriptor) .setParamsExtractor( request -> { RequestParamsBuilder builder = RequestParamsBuilder.create(); builder.add("parent", String.valueOf(request.getParent())); return builder.build(); }) .build(); GrpcCallSettings updatePostureDeploymentTransportSettings = GrpcCallSettings.newBuilder() .setMethodDescriptor(updatePostureDeploymentMethodDescriptor) .setParamsExtractor( request -> { RequestParamsBuilder builder = RequestParamsBuilder.create(); builder.add( "posture_deployment.name", String.valueOf(request.getPostureDeployment().getName())); return builder.build(); }) .build(); GrpcCallSettings deletePostureDeploymentTransportSettings = GrpcCallSettings.newBuilder() .setMethodDescriptor(deletePostureDeploymentMethodDescriptor) .setParamsExtractor( request -> { RequestParamsBuilder builder = RequestParamsBuilder.create(); builder.add("name", String.valueOf(request.getName())); return builder.build(); }) .build(); GrpcCallSettings listPostureTemplatesTransportSettings = GrpcCallSettings.newBuilder() .setMethodDescriptor(listPostureTemplatesMethodDescriptor) .setParamsExtractor( request -> { RequestParamsBuilder builder = RequestParamsBuilder.create(); builder.add("parent", String.valueOf(request.getParent())); return builder.build(); }) .build(); GrpcCallSettings getPostureTemplateTransportSettings = GrpcCallSettings.newBuilder() .setMethodDescriptor(getPostureTemplateMethodDescriptor) .setParamsExtractor( request -> { RequestParamsBuilder builder = RequestParamsBuilder.create(); builder.add("name", String.valueOf(request.getName())); return builder.build(); }) .build(); GrpcCallSettings listLocationsTransportSettings = GrpcCallSettings.newBuilder() .setMethodDescriptor(listLocationsMethodDescriptor) .setParamsExtractor( request -> { RequestParamsBuilder builder = RequestParamsBuilder.create(); builder.add("name", String.valueOf(request.getName())); return builder.build(); }) .build(); GrpcCallSettings getLocationTransportSettings = GrpcCallSettings.newBuilder() .setMethodDescriptor(getLocationMethodDescriptor) .setParamsExtractor( request -> { RequestParamsBuilder builder = RequestParamsBuilder.create(); builder.add("name", String.valueOf(request.getName())); return builder.build(); }) .build(); this.listPosturesCallable = callableFactory.createUnaryCallable( listPosturesTransportSettings, settings.listPosturesSettings(), clientContext); this.listPosturesPagedCallable = callableFactory.createPagedCallable( listPosturesTransportSettings, settings.listPosturesSettings(), clientContext); this.listPostureRevisionsCallable = callableFactory.createUnaryCallable( listPostureRevisionsTransportSettings, settings.listPostureRevisionsSettings(), clientContext); this.listPostureRevisionsPagedCallable = callableFactory.createPagedCallable( listPostureRevisionsTransportSettings, settings.listPostureRevisionsSettings(), clientContext); this.getPostureCallable = callableFactory.createUnaryCallable( getPostureTransportSettings, settings.getPostureSettings(), clientContext); this.createPostureCallable = callableFactory.createUnaryCallable( createPostureTransportSettings, settings.createPostureSettings(), clientContext); this.createPostureOperationCallable = callableFactory.createOperationCallable( createPostureTransportSettings, settings.createPostureOperationSettings(), clientContext, operationsStub); this.updatePostureCallable = callableFactory.createUnaryCallable( updatePostureTransportSettings, settings.updatePostureSettings(), clientContext); this.updatePostureOperationCallable = callableFactory.createOperationCallable( updatePostureTransportSettings, settings.updatePostureOperationSettings(), clientContext, operationsStub); this.deletePostureCallable = callableFactory.createUnaryCallable( deletePostureTransportSettings, settings.deletePostureSettings(), clientContext); this.deletePostureOperationCallable = callableFactory.createOperationCallable( deletePostureTransportSettings, settings.deletePostureOperationSettings(), clientContext, operationsStub); this.extractPostureCallable = callableFactory.createUnaryCallable( extractPostureTransportSettings, settings.extractPostureSettings(), clientContext); this.extractPostureOperationCallable = callableFactory.createOperationCallable( extractPostureTransportSettings, settings.extractPostureOperationSettings(), clientContext, operationsStub); this.listPostureDeploymentsCallable = callableFactory.createUnaryCallable( listPostureDeploymentsTransportSettings, settings.listPostureDeploymentsSettings(), clientContext); this.listPostureDeploymentsPagedCallable = callableFactory.createPagedCallable( listPostureDeploymentsTransportSettings, settings.listPostureDeploymentsSettings(), clientContext); this.getPostureDeploymentCallable = callableFactory.createUnaryCallable( getPostureDeploymentTransportSettings, settings.getPostureDeploymentSettings(), clientContext); this.createPostureDeploymentCallable = callableFactory.createUnaryCallable( createPostureDeploymentTransportSettings, settings.createPostureDeploymentSettings(), clientContext); this.createPostureDeploymentOperationCallable = callableFactory.createOperationCallable( createPostureDeploymentTransportSettings, settings.createPostureDeploymentOperationSettings(), clientContext, operationsStub); this.updatePostureDeploymentCallable = callableFactory.createUnaryCallable( updatePostureDeploymentTransportSettings, settings.updatePostureDeploymentSettings(), clientContext); this.updatePostureDeploymentOperationCallable = callableFactory.createOperationCallable( updatePostureDeploymentTransportSettings, settings.updatePostureDeploymentOperationSettings(), clientContext, operationsStub); this.deletePostureDeploymentCallable = callableFactory.createUnaryCallable( deletePostureDeploymentTransportSettings, settings.deletePostureDeploymentSettings(), clientContext); this.deletePostureDeploymentOperationCallable = callableFactory.createOperationCallable( deletePostureDeploymentTransportSettings, settings.deletePostureDeploymentOperationSettings(), clientContext, operationsStub); this.listPostureTemplatesCallable = callableFactory.createUnaryCallable( listPostureTemplatesTransportSettings, settings.listPostureTemplatesSettings(), clientContext); this.listPostureTemplatesPagedCallable = callableFactory.createPagedCallable( listPostureTemplatesTransportSettings, settings.listPostureTemplatesSettings(), clientContext); this.getPostureTemplateCallable = callableFactory.createUnaryCallable( getPostureTemplateTransportSettings, settings.getPostureTemplateSettings(), clientContext); this.listLocationsCallable = callableFactory.createUnaryCallable( listLocationsTransportSettings, settings.listLocationsSettings(), clientContext); this.listLocationsPagedCallable = callableFactory.createPagedCallable( listLocationsTransportSettings, settings.listLocationsSettings(), clientContext); this.getLocationCallable = callableFactory.createUnaryCallable( getLocationTransportSettings, settings.getLocationSettings(), clientContext); this.backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); } public GrpcOperationsStub getOperationsStub() { return operationsStub; } @Override public UnaryCallable listPosturesCallable() { return listPosturesCallable; } @Override public UnaryCallable listPosturesPagedCallable() { return listPosturesPagedCallable; } @Override public UnaryCallable listPostureRevisionsCallable() { return listPostureRevisionsCallable; } @Override public UnaryCallable listPostureRevisionsPagedCallable() { return listPostureRevisionsPagedCallable; } @Override public UnaryCallable getPostureCallable() { return getPostureCallable; } @Override public UnaryCallable createPostureCallable() { return createPostureCallable; } @Override public OperationCallable createPostureOperationCallable() { return createPostureOperationCallable; } @Override public UnaryCallable updatePostureCallable() { return updatePostureCallable; } @Override public OperationCallable updatePostureOperationCallable() { return updatePostureOperationCallable; } @Override public UnaryCallable deletePostureCallable() { return deletePostureCallable; } @Override public OperationCallable deletePostureOperationCallable() { return deletePostureOperationCallable; } @Override public UnaryCallable extractPostureCallable() { return extractPostureCallable; } @Override public OperationCallable extractPostureOperationCallable() { return extractPostureOperationCallable; } @Override public UnaryCallable listPostureDeploymentsCallable() { return listPostureDeploymentsCallable; } @Override public UnaryCallable listPostureDeploymentsPagedCallable() { return listPostureDeploymentsPagedCallable; } @Override public UnaryCallable getPostureDeploymentCallable() { return getPostureDeploymentCallable; } @Override public UnaryCallable createPostureDeploymentCallable() { return createPostureDeploymentCallable; } @Override public OperationCallable createPostureDeploymentOperationCallable() { return createPostureDeploymentOperationCallable; } @Override public UnaryCallable updatePostureDeploymentCallable() { return updatePostureDeploymentCallable; } @Override public OperationCallable updatePostureDeploymentOperationCallable() { return updatePostureDeploymentOperationCallable; } @Override public UnaryCallable deletePostureDeploymentCallable() { return deletePostureDeploymentCallable; } @Override public OperationCallable deletePostureDeploymentOperationCallable() { return deletePostureDeploymentOperationCallable; } @Override public UnaryCallable listPostureTemplatesCallable() { return listPostureTemplatesCallable; } @Override public UnaryCallable listPostureTemplatesPagedCallable() { return listPostureTemplatesPagedCallable; } @Override public UnaryCallable getPostureTemplateCallable() { return getPostureTemplateCallable; } @Override public UnaryCallable listLocationsCallable() { return listLocationsCallable; } @Override public UnaryCallable listLocationsPagedCallable() { return listLocationsPagedCallable; } @Override public UnaryCallable getLocationCallable() { return getLocationCallable; } @Override public final void close() { try { backgroundResources.close(); } catch (RuntimeException e) { throw e; } catch (Exception e) { throw new IllegalStateException("Failed to close resource", e); } } @Override public void shutdown() { backgroundResources.shutdown(); } @Override public boolean isShutdown() { return backgroundResources.isShutdown(); } @Override public boolean isTerminated() { return backgroundResources.isTerminated(); } @Override public void shutdownNow() { backgroundResources.shutdownNow(); } @Override public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { return backgroundResources.awaitTermination(duration, unit); } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy