Skip to content
This repository has been archived by the owner on Sep 16, 2023. It is now read-only.

feat: add Application.service_account #234

Merged
merged 6 commits into from May 6, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
@@ -1,5 +1,5 @@
/*
* Copyright 2021 Google LLC
* Copyright 2022 Google LLC
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't update year

*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -37,10 +37,11 @@
* calls that map to API methods. Sample code to get started:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* try (ApplicationsClient applicationsClient = ApplicationsClient.create()) {
* GetApplicationRequest request =
* GetApplicationRequest.newBuilder().setName("name3373707").build();
* Application response = applicationsClient.getApplication(request);
* String name = "name3373707";
* Application response = applicationsClient.getApplication(name);
* }
* }</pre>
*
Expand Down Expand Up @@ -73,6 +74,8 @@
* <p>To customize credentials:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* ApplicationsSettings applicationsSettings =
* ApplicationsSettings.newBuilder()
* .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
Expand All @@ -83,6 +86,8 @@
* <p>To customize the endpoint:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* ApplicationsSettings applicationsSettings =
* ApplicationsSettings.newBuilder().setEndpoint(myEndpoint).build();
* ApplicationsClient applicationsClient = ApplicationsClient.create(applicationsSettings);
Expand Down Expand Up @@ -160,6 +165,31 @@ public final OperationsClient getOperationsClient() {
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* try (ApplicationsClient applicationsClient = ApplicationsClient.create()) {
* String name = "name3373707";
* Application response = applicationsClient.getApplication(name);
* }
* }</pre>
*
* @param name Name of the Application resource to get. Example: `apps/myapp`.
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
*/
public final Application getApplication(String name) {
GetApplicationRequest request = GetApplicationRequest.newBuilder().setName(name).build();
return getApplication(request);
}

// AUTO-GENERATED DOCUMENTATION AND METHOD.
/**
* Gets information about an application.
*
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* try (ApplicationsClient applicationsClient = ApplicationsClient.create()) {
* GetApplicationRequest request =
* GetApplicationRequest.newBuilder().setName("name3373707").build();
Expand All @@ -181,6 +211,8 @@ public final Application getApplication(GetApplicationRequest request) {
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* try (ApplicationsClient applicationsClient = ApplicationsClient.create()) {
* GetApplicationRequest request =
* GetApplicationRequest.newBuilder().setName("name3373707").build();
Expand Down Expand Up @@ -211,6 +243,8 @@ public final UnaryCallable<GetApplicationRequest, Application> getApplicationCal
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* try (ApplicationsClient applicationsClient = ApplicationsClient.create()) {
* CreateApplicationRequest request =
* CreateApplicationRequest.newBuilder()
Expand Down Expand Up @@ -244,6 +278,8 @@ public final OperationFuture<Application, OperationMetadataV1> createApplication
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* try (ApplicationsClient applicationsClient = ApplicationsClient.create()) {
* CreateApplicationRequest request =
* CreateApplicationRequest.newBuilder()
Expand Down Expand Up @@ -277,6 +313,8 @@ public final OperationFuture<Application, OperationMetadataV1> createApplication
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* try (ApplicationsClient applicationsClient = ApplicationsClient.create()) {
* CreateApplicationRequest request =
* CreateApplicationRequest.newBuilder()
Expand All @@ -301,11 +339,14 @@ public final UnaryCallable<CreateApplicationRequest, Operation> createApplicatio
* <li>`auth_domain` - Google authentication domain for controlling user access to the
* application.
* <li>`default_cookie_expiration` - Cookie expiration policy for the application.
* <li>`iap` - Identity-Aware Proxy properties for the application.
* </ul>
*
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* try (ApplicationsClient applicationsClient = ApplicationsClient.create()) {
* UpdateApplicationRequest request =
* UpdateApplicationRequest.newBuilder()
Expand Down Expand Up @@ -333,11 +374,14 @@ public final OperationFuture<Application, OperationMetadataV1> updateApplication
* <li>`auth_domain` - Google authentication domain for controlling user access to the
* application.
* <li>`default_cookie_expiration` - Cookie expiration policy for the application.
* <li>`iap` - Identity-Aware Proxy properties for the application.
* </ul>
*
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* try (ApplicationsClient applicationsClient = ApplicationsClient.create()) {
* UpdateApplicationRequest request =
* UpdateApplicationRequest.newBuilder()
Expand Down Expand Up @@ -365,11 +409,14 @@ public final OperationFuture<Application, OperationMetadataV1> updateApplication
* <li>`auth_domain` - Google authentication domain for controlling user access to the
* application.
* <li>`default_cookie_expiration` - Cookie expiration policy for the application.
* <li>`iap` - Identity-Aware Proxy properties for the application.
* </ul>
*
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* try (ApplicationsClient applicationsClient = ApplicationsClient.create()) {
* UpdateApplicationRequest request =
* UpdateApplicationRequest.newBuilder()
Expand Down Expand Up @@ -401,6 +448,8 @@ public final UnaryCallable<UpdateApplicationRequest, Operation> updateApplicatio
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* try (ApplicationsClient applicationsClient = ApplicationsClient.create()) {
* RepairApplicationRequest request =
* RepairApplicationRequest.newBuilder().setName("name3373707").build();
Expand Down Expand Up @@ -429,6 +478,8 @@ public final OperationFuture<Application, OperationMetadataV1> repairApplication
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* try (ApplicationsClient applicationsClient = ApplicationsClient.create()) {
* RepairApplicationRequest request =
* RepairApplicationRequest.newBuilder().setName("name3373707").build();
Expand Down Expand Up @@ -457,6 +508,8 @@ public final OperationFuture<Application, OperationMetadataV1> repairApplication
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* try (ApplicationsClient applicationsClient = ApplicationsClient.create()) {
* RepairApplicationRequest request =
* RepairApplicationRequest.newBuilder().setName("name3373707").build();
Expand Down
@@ -1,5 +1,5 @@
/*
* Copyright 2021 Google LLC
* Copyright 2022 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -51,6 +51,8 @@
* <p>For example, to set the total timeout of getApplication to 30 seconds:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* ApplicationsSettings.Builder applicationsSettingsBuilder = ApplicationsSettings.newBuilder();
* applicationsSettingsBuilder
* .getApplicationSettings()
Expand Down
@@ -1,5 +1,5 @@
/*
* Copyright 2021 Google LLC
* Copyright 2022 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -43,6 +43,8 @@
* calls that map to API methods. Sample code to get started:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* try (AuthorizedCertificatesClient authorizedCertificatesClient =
* AuthorizedCertificatesClient.create()) {
* GetAuthorizedCertificateRequest request =
Expand Down Expand Up @@ -85,6 +87,8 @@
* <p>To customize credentials:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* AuthorizedCertificatesSettings authorizedCertificatesSettings =
* AuthorizedCertificatesSettings.newBuilder()
* .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
Expand All @@ -96,6 +100,8 @@
* <p>To customize the endpoint:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* AuthorizedCertificatesSettings authorizedCertificatesSettings =
* AuthorizedCertificatesSettings.newBuilder().setEndpoint(myEndpoint).build();
* AuthorizedCertificatesClient authorizedCertificatesClient =
Expand Down Expand Up @@ -165,6 +171,8 @@ public AuthorizedCertificatesStub getStub() {
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* try (AuthorizedCertificatesClient authorizedCertificatesClient =
* AuthorizedCertificatesClient.create()) {
* ListAuthorizedCertificatesRequest request =
Expand Down Expand Up @@ -196,6 +204,8 @@ public final ListAuthorizedCertificatesPagedResponse listAuthorizedCertificates(
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* try (AuthorizedCertificatesClient authorizedCertificatesClient =
* AuthorizedCertificatesClient.create()) {
* ListAuthorizedCertificatesRequest request =
Expand Down Expand Up @@ -229,6 +239,8 @@ public final ListAuthorizedCertificatesPagedResponse listAuthorizedCertificates(
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* try (AuthorizedCertificatesClient authorizedCertificatesClient =
* AuthorizedCertificatesClient.create()) {
* ListAuthorizedCertificatesRequest request =
Expand Down Expand Up @@ -266,6 +278,8 @@ public final ListAuthorizedCertificatesPagedResponse listAuthorizedCertificates(
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* try (AuthorizedCertificatesClient authorizedCertificatesClient =
* AuthorizedCertificatesClient.create()) {
* GetAuthorizedCertificateRequest request =
Expand Down Expand Up @@ -293,6 +307,8 @@ public final AuthorizedCertificate getAuthorizedCertificate(
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* try (AuthorizedCertificatesClient authorizedCertificatesClient =
* AuthorizedCertificatesClient.create()) {
* GetAuthorizedCertificateRequest request =
Expand All @@ -319,6 +335,8 @@ public final AuthorizedCertificate getAuthorizedCertificate(
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* try (AuthorizedCertificatesClient authorizedCertificatesClient =
* AuthorizedCertificatesClient.create()) {
* CreateAuthorizedCertificateRequest request =
Expand Down Expand Up @@ -346,6 +364,8 @@ public final AuthorizedCertificate createAuthorizedCertificate(
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* try (AuthorizedCertificatesClient authorizedCertificatesClient =
* AuthorizedCertificatesClient.create()) {
* CreateAuthorizedCertificateRequest request =
Expand Down Expand Up @@ -375,6 +395,8 @@ public final AuthorizedCertificate createAuthorizedCertificate(
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* try (AuthorizedCertificatesClient authorizedCertificatesClient =
* AuthorizedCertificatesClient.create()) {
* UpdateAuthorizedCertificateRequest request =
Expand Down Expand Up @@ -406,6 +428,8 @@ public final AuthorizedCertificate updateAuthorizedCertificate(
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* try (AuthorizedCertificatesClient authorizedCertificatesClient =
* AuthorizedCertificatesClient.create()) {
* UpdateAuthorizedCertificateRequest request =
Expand Down Expand Up @@ -433,6 +457,8 @@ public final AuthorizedCertificate updateAuthorizedCertificate(
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* try (AuthorizedCertificatesClient authorizedCertificatesClient =
* AuthorizedCertificatesClient.create()) {
* DeleteAuthorizedCertificateRequest request =
Expand All @@ -455,6 +481,8 @@ public final void deleteAuthorizedCertificate(DeleteAuthorizedCertificateRequest
* <p>Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* try (AuthorizedCertificatesClient authorizedCertificatesClient =
* AuthorizedCertificatesClient.create()) {
* DeleteAuthorizedCertificateRequest request =
Expand Down
@@ -1,5 +1,5 @@
/*
* Copyright 2021 Google LLC
* Copyright 2022 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -53,6 +53,8 @@
* <p>For example, to set the total timeout of getAuthorizedCertificate to 30 seconds:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* AuthorizedCertificatesSettings.Builder authorizedCertificatesSettingsBuilder =
* AuthorizedCertificatesSettings.newBuilder();
* authorizedCertificatesSettingsBuilder
Expand Down