/// <summary>Snippet for GetIapSettings</summary> public void GetIapSettingsRequestObject() { // Snippet: GetIapSettings(GetIapSettingsRequest, CallSettings) // Create client IdentityAwareProxyAdminServiceClient identityAwareProxyAdminServiceClient = IdentityAwareProxyAdminServiceClient.Create(); // Initialize request argument(s) GetIapSettingsRequest request = new GetIapSettingsRequest { Name = "", }; // Make the request IapSettings response = identityAwareProxyAdminServiceClient.GetIapSettings(request); // End snippet }
/// <summary>Snippet for GetIapSettingsAsync</summary> public async Task GetIapSettingsRequestObjectAsync() { // Snippet: GetIapSettingsAsync(GetIapSettingsRequest, CallSettings) // Additional: GetIapSettingsAsync(GetIapSettingsRequest, CancellationToken) // Create client IdentityAwareProxyAdminServiceClient identityAwareProxyAdminServiceClient = await IdentityAwareProxyAdminServiceClient.CreateAsync(); // Initialize request argument(s) GetIapSettingsRequest request = new GetIapSettingsRequest { Name = "", }; // Make the request IapSettings response = await identityAwareProxyAdminServiceClient.GetIapSettingsAsync(request); // End snippet }
public void GetIapSettingsRequestObject() { moq::Mock <IdentityAwareProxyAdminService.IdentityAwareProxyAdminServiceClient> mockGrpcClient = new moq::Mock <IdentityAwareProxyAdminService.IdentityAwareProxyAdminServiceClient>(moq::MockBehavior.Strict); GetIapSettingsRequest request = new GetIapSettingsRequest { Name = "name1c9368b0", }; IapSettings expectedResponse = new IapSettings { Name = "name1c9368b0", AccessSettings = new AccessSettings(), ApplicationSettings = new ApplicationSettings(), }; mockGrpcClient.Setup(x => x.GetIapSettings(request, moq::It.IsAny <grpccore::CallOptions>())).Returns(expectedResponse); IdentityAwareProxyAdminServiceClient client = new IdentityAwareProxyAdminServiceClientImpl(mockGrpcClient.Object, null); IapSettings response = client.GetIapSettings(request); xunit::Assert.Same(expectedResponse, response); mockGrpcClient.VerifyAll(); }
public async stt::Task GetIapSettingsRequestObjectAsync() { moq::Mock <IdentityAwareProxyAdminService.IdentityAwareProxyAdminServiceClient> mockGrpcClient = new moq::Mock <IdentityAwareProxyAdminService.IdentityAwareProxyAdminServiceClient>(moq::MockBehavior.Strict); GetIapSettingsRequest request = new GetIapSettingsRequest { Name = "name1c9368b0", }; IapSettings expectedResponse = new IapSettings { Name = "name1c9368b0", AccessSettings = new AccessSettings(), ApplicationSettings = new ApplicationSettings(), }; mockGrpcClient.Setup(x => x.GetIapSettingsAsync(request, moq::It.IsAny <grpccore::CallOptions>())).Returns(new grpccore::AsyncUnaryCall <IapSettings>(stt::Task.FromResult(expectedResponse), null, null, null, null)); IdentityAwareProxyAdminServiceClient client = new IdentityAwareProxyAdminServiceClientImpl(mockGrpcClient.Object, null); IapSettings responseCallSettings = await client.GetIapSettingsAsync(request, gaxgrpc::CallSettings.FromCancellationToken(st::CancellationToken.None)); xunit::Assert.Same(expectedResponse, responseCallSettings); IapSettings responseCancellationToken = await client.GetIapSettingsAsync(request, st::CancellationToken.None); xunit::Assert.Same(expectedResponse, responseCancellationToken); mockGrpcClient.VerifyAll(); }
/// <summary> /// Gets the IAP settings on a particular IAP protected resource. /// </summary> /// <param name="request">The request object containing all of the parameters for the API call.</param> /// <param name="callSettings">If not null, applies overrides to this RPC call.</param> /// <returns>A Task containing the RPC response.</returns> public override stt::Task <IapSettings> GetIapSettingsAsync(GetIapSettingsRequest request, gaxgrpc::CallSettings callSettings = null) { Modify_GetIapSettingsRequest(ref request, ref callSettings); return(_callGetIapSettings.Async(request, callSettings)); }
/// <summary> /// Gets the IAP settings on a particular IAP protected resource. /// </summary> /// <param name="request">The request object containing all of the parameters for the API call.</param> /// <param name="callSettings">If not null, applies overrides to this RPC call.</param> /// <returns>The RPC response.</returns> public override IapSettings GetIapSettings(GetIapSettingsRequest request, gaxgrpc::CallSettings callSettings = null) { Modify_GetIapSettingsRequest(ref request, ref callSettings); return(_callGetIapSettings.Sync(request, callSettings)); }
partial void Modify_GetIapSettingsRequest(ref GetIapSettingsRequest request, ref gaxgrpc::CallSettings settings);
/// <summary> /// Gets the IAP settings on a particular IAP protected resource. /// </summary> /// <param name="request">The request object containing all of the parameters for the API call.</param> /// <param name="cancellationToken">A <see cref="st::CancellationToken"/> to use for this RPC.</param> /// <returns>A Task containing the RPC response.</returns> public virtual stt::Task <IapSettings> GetIapSettingsAsync(GetIapSettingsRequest request, st::CancellationToken cancellationToken) => GetIapSettingsAsync(request, gaxgrpc::CallSettings.FromCancellationToken(cancellationToken));
/// <summary> /// Gets the IAP settings on a particular IAP protected resource. /// </summary> /// <param name="request">The request object containing all of the parameters for the API call.</param> /// <param name="callSettings">If not null, applies overrides to this RPC call.</param> /// <returns>A Task containing the RPC response.</returns> public virtual stt::Task <IapSettings> GetIapSettingsAsync(GetIapSettingsRequest request, gaxgrpc::CallSettings callSettings = null) => throw new sys::NotImplementedException();
/// <summary> /// Gets the IAP settings on a particular IAP protected resource. /// </summary> /// <param name="request">The request object containing all of the parameters for the API call.</param> /// <param name="callSettings">If not null, applies overrides to this RPC call.</param> /// <returns>The RPC response.</returns> public virtual IapSettings GetIapSettings(GetIapSettingsRequest request, gaxgrpc::CallSettings callSettings = null) => throw new sys::NotImplementedException();