-
Notifications
You must be signed in to change notification settings - Fork 53
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[ggj][engx][codegen] fix: handle back-compat casing for IAMCredential…
…s API (#601) * fix: fix dep ordering in Bazel dedupe rules * chore: centralize all Gapic class name getters * fix: use gapic-remapped names in package-info.java * fix: revert unrelated changes * fix: handle back-compat casing for IAMCredentials API
- Loading branch information
Showing
19 changed files
with
2,484 additions
and
31 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
package(default_visibility = ["//visibility:public"]) | ||
|
||
filegroup( | ||
name = "goldens_files", | ||
srcs = glob(["*.java"]), | ||
) |
113 changes: 113 additions & 0 deletions
113
test/integration/goldens/credentials/GrpcIamCredentialsCallableFactory.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,113 @@ | ||
/* | ||
* Copyright 2020 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.iam.credentials.v1.stub; | ||
|
||
import com.google.api.gax.grpc.GrpcCallSettings; | ||
import com.google.api.gax.grpc.GrpcCallableFactory; | ||
import com.google.api.gax.grpc.GrpcStubCallableFactory; | ||
import com.google.api.gax.rpc.BatchingCallSettings; | ||
import com.google.api.gax.rpc.BidiStreamingCallable; | ||
import com.google.api.gax.rpc.ClientContext; | ||
import com.google.api.gax.rpc.ClientStreamingCallable; | ||
import com.google.api.gax.rpc.OperationCallSettings; | ||
import com.google.api.gax.rpc.OperationCallable; | ||
import com.google.api.gax.rpc.PagedCallSettings; | ||
import com.google.api.gax.rpc.ServerStreamingCallSettings; | ||
import com.google.api.gax.rpc.ServerStreamingCallable; | ||
import com.google.api.gax.rpc.StreamingCallSettings; | ||
import com.google.api.gax.rpc.UnaryCallSettings; | ||
import com.google.api.gax.rpc.UnaryCallable; | ||
import com.google.longrunning.Operation; | ||
import com.google.longrunning.stub.OperationsStub; | ||
import javax.annotation.Generated; | ||
|
||
// AUTO-GENERATED DOCUMENTATION AND CLASS. | ||
/** | ||
* gRPC callable factory implementation for the IAMCredentials service API. | ||
* | ||
* <p>This class is for advanced usage. | ||
*/ | ||
@Generated("by gapic-generator") | ||
public class GrpcIamCredentialsCallableFactory implements GrpcStubCallableFactory { | ||
|
||
@Override | ||
public <RequestT, ResponseT> UnaryCallable<RequestT, ResponseT> createUnaryCallable( | ||
GrpcCallSettings<RequestT, ResponseT> grpcCallSettings, | ||
UnaryCallSettings<RequestT, ResponseT> callSettings, | ||
ClientContext clientContext) { | ||
return GrpcCallableFactory.createUnaryCallable(grpcCallSettings, callSettings, clientContext); | ||
} | ||
|
||
@Override | ||
public <RequestT, ResponseT, PagedListResponseT> | ||
UnaryCallable<RequestT, PagedListResponseT> createPagedCallable( | ||
GrpcCallSettings<RequestT, ResponseT> grpcCallSettings, | ||
PagedCallSettings<RequestT, ResponseT, PagedListResponseT> callSettings, | ||
ClientContext clientContext) { | ||
return GrpcCallableFactory.createPagedCallable(grpcCallSettings, callSettings, clientContext); | ||
} | ||
|
||
@Override | ||
public <RequestT, ResponseT> UnaryCallable<RequestT, ResponseT> createBatchingCallable( | ||
GrpcCallSettings<RequestT, ResponseT> grpcCallSettings, | ||
BatchingCallSettings<RequestT, ResponseT> callSettings, | ||
ClientContext clientContext) { | ||
return GrpcCallableFactory.createBatchingCallable( | ||
grpcCallSettings, callSettings, clientContext); | ||
} | ||
|
||
@Override | ||
public <RequestT, ResponseT, MetadataT> | ||
OperationCallable<RequestT, ResponseT, MetadataT> createOperationCallable( | ||
GrpcCallSettings<RequestT, Operation> grpcCallSettings, | ||
OperationCallSettings<RequestT, ResponseT, MetadataT> callSettings, | ||
ClientContext clientContext, | ||
OperationsStub operationsStub) { | ||
return GrpcCallableFactory.createOperationCallable( | ||
grpcCallSettings, callSettings, clientContext, operationsStub); | ||
} | ||
|
||
@Override | ||
public <RequestT, ResponseT> | ||
BidiStreamingCallable<RequestT, ResponseT> createBidiStreamingCallable( | ||
GrpcCallSettings<RequestT, ResponseT> grpcCallSettings, | ||
StreamingCallSettings<RequestT, ResponseT> callSettings, | ||
ClientContext clientContext) { | ||
return GrpcCallableFactory.createBidiStreamingCallable( | ||
grpcCallSettings, callSettings, clientContext); | ||
} | ||
|
||
@Override | ||
public <RequestT, ResponseT> | ||
ServerStreamingCallable<RequestT, ResponseT> createServerStreamingCallable( | ||
GrpcCallSettings<RequestT, ResponseT> grpcCallSettings, | ||
ServerStreamingCallSettings<RequestT, ResponseT> callSettings, | ||
ClientContext clientContext) { | ||
return GrpcCallableFactory.createServerStreamingCallable( | ||
grpcCallSettings, callSettings, clientContext); | ||
} | ||
|
||
@Override | ||
public <RequestT, ResponseT> | ||
ClientStreamingCallable<RequestT, ResponseT> createClientStreamingCallable( | ||
GrpcCallSettings<RequestT, ResponseT> grpcCallSettings, | ||
StreamingCallSettings<RequestT, ResponseT> callSettings, | ||
ClientContext clientContext) { | ||
return GrpcCallableFactory.createClientStreamingCallable( | ||
grpcCallSettings, callSettings, clientContext); | ||
} | ||
} |
Oops, something went wrong.