Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: update autogenerated snippet disclaimer #1029

Merged
merged 2 commits into from
Aug 24, 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.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,16 @@ public class CommentComposer {
Arrays.asList(
CommentStatement.withComment(
LineComment.withComment(
"This snippet has been automatically generated for illustrative purposes only.")),
"This snippet has been automatically generated and should be regarded as a code template only.")),
CommentStatement.withComment(
LineComment.withComment("It will require modifications to work:")),
CommentStatement.withComment(
LineComment.withComment(
"- It may require correct/in-range values for request initialization.")),
CommentStatement.withComment(
LineComment.withComment(
"- It may require specifying regional endpoints when creating the service client as shown in")),
CommentStatement.withComment(
LineComment.withComment(
"It may require modifications to work in your environment.")));
"https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library")));
}
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,11 @@ import javax.annotation.Generated;
* 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.
* // This snippet has been automatically generated and should be regarded as a code template only.
* // It will require modifications to work:
* // - It may require correct/in-range values for request initialization.
* // - It may require specifying regional endpoints when creating the service client as shown in
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
* try (BookshopClient bookshopClient = BookshopClient.create()) {
* int booksCount = 1618425911;
* List<Book> books = new ArrayList<>();
Expand Down Expand Up @@ -54,8 +57,11 @@ import javax.annotation.Generated;
* <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.
* // This snippet has been automatically generated and should be regarded as a code template only.
* // It will require modifications to work:
* // - It may require correct/in-range values for request initialization.
* // - It may require specifying regional endpoints when creating the service client as shown in
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
* BookshopSettings bookshopSettings =
* BookshopSettings.newBuilder()
* .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
Expand All @@ -66,8 +72,11 @@ import javax.annotation.Generated;
* <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.
* // This snippet has been automatically generated and should be regarded as a code template only.
* // It will require modifications to work:
* // - It may require correct/in-range values for request initialization.
* // - It may require specifying regional endpoints when creating the service client as shown in
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
* BookshopSettings bookshopSettings =
* BookshopSettings.newBuilder().setEndpoint(myEndpoint).build();
* BookshopClient bookshopClient = BookshopClient.create(bookshopSettings);
Expand Down Expand Up @@ -129,8 +138,11 @@ public class BookshopClient implements BackgroundResource {
* Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* // This snippet has been automatically generated and should be regarded as a code template only.
* // It will require modifications to work:
* // - It may require correct/in-range values for request initialization.
* // - It may require specifying regional endpoints when creating the service client as shown in
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
* try (BookshopClient bookshopClient = BookshopClient.create()) {
* int booksCount = 1618425911;
* List<Book> books = new ArrayList<>();
Expand All @@ -153,8 +165,11 @@ public class BookshopClient implements BackgroundResource {
* Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* // This snippet has been automatically generated and should be regarded as a code template only.
* // It will require modifications to work:
* // - It may require correct/in-range values for request initialization.
* // - It may require specifying regional endpoints when creating the service client as shown in
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
* try (BookshopClient bookshopClient = BookshopClient.create()) {
* String booksList = "booksList2-1119589686";
* List<Book> books = new ArrayList<>();
Expand All @@ -177,8 +192,11 @@ public class BookshopClient implements BackgroundResource {
* Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* // This snippet has been automatically generated and should be regarded as a code template only.
* // It will require modifications to work:
* // - It may require correct/in-range values for request initialization.
* // - It may require specifying regional endpoints when creating the service client as shown in
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
* try (BookshopClient bookshopClient = BookshopClient.create()) {
* GetBookRequest request =
* GetBookRequest.newBuilder()
Expand All @@ -202,8 +220,11 @@ public class BookshopClient implements BackgroundResource {
* Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* // This snippet has been automatically generated and should be regarded as a code template only.
* // It will require modifications to work:
* // - It may require correct/in-range values for request initialization.
* // - It may require specifying regional endpoints when creating the service client as shown in
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
* try (BookshopClient bookshopClient = BookshopClient.create()) {
* GetBookRequest request =
* GetBookRequest.newBuilder()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,11 @@ import javax.annotation.Generated;
* 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.
* // This snippet has been automatically generated and should be regarded as a code template only.
* // It will require modifications to work:
* // - It may require correct/in-range values for request initialization.
* // - It may require specifying regional endpoints when creating the service client as shown in
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
* try (DeprecatedServiceClient deprecatedServiceClient = DeprecatedServiceClient.create()) {
* FibonacciRequest request = FibonacciRequest.newBuilder().setValue(111972721).build();
* deprecatedServiceClient.fastFibonacci(request);
Expand Down Expand Up @@ -53,8 +56,11 @@ import javax.annotation.Generated;
* <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.
* // This snippet has been automatically generated and should be regarded as a code template only.
* // It will require modifications to work:
* // - It may require correct/in-range values for request initialization.
* // - It may require specifying regional endpoints when creating the service client as shown in
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
* DeprecatedServiceSettings deprecatedServiceSettings =
* DeprecatedServiceSettings.newBuilder()
* .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
Expand All @@ -66,8 +72,11 @@ import javax.annotation.Generated;
* <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.
* // This snippet has been automatically generated and should be regarded as a code template only.
* // It will require modifications to work:
* // - It may require correct/in-range values for request initialization.
* // - It may require specifying regional endpoints when creating the service client as shown in
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
* DeprecatedServiceSettings deprecatedServiceSettings =
* DeprecatedServiceSettings.newBuilder().setEndpoint(myEndpoint).build();
* DeprecatedServiceClient deprecatedServiceClient =
Expand Down Expand Up @@ -134,8 +143,11 @@ public class DeprecatedServiceClient implements BackgroundResource {
* Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* // This snippet has been automatically generated and should be regarded as a code template only.
* // It will require modifications to work:
* // - It may require correct/in-range values for request initialization.
* // - It may require specifying regional endpoints when creating the service client as shown in
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
* try (DeprecatedServiceClient deprecatedServiceClient = DeprecatedServiceClient.create()) {
* FibonacciRequest request = FibonacciRequest.newBuilder().setValue(111972721).build();
* deprecatedServiceClient.fastFibonacci(request);
Expand All @@ -154,8 +166,11 @@ public class DeprecatedServiceClient implements BackgroundResource {
* Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* // This snippet has been automatically generated and should be regarded as a code template only.
* // It will require modifications to work:
* // - It may require correct/in-range values for request initialization.
* // - It may require specifying regional endpoints when creating the service client as shown in
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
* try (DeprecatedServiceClient deprecatedServiceClient = DeprecatedServiceClient.create()) {
* FibonacciRequest request = FibonacciRequest.newBuilder().setValue(111972721).build();
* ApiFuture<Empty> future = deprecatedServiceClient.fastFibonacciCallable().futureCall(request);
Expand All @@ -173,8 +188,11 @@ public class DeprecatedServiceClient implements BackgroundResource {
* Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* // This snippet has been automatically generated and should be regarded as a code template only.
* // It will require modifications to work:
* // - It may require correct/in-range values for request initialization.
* // - It may require specifying regional endpoints when creating the service client as shown in
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
* try (DeprecatedServiceClient deprecatedServiceClient = DeprecatedServiceClient.create()) {
* FibonacciRequest request = FibonacciRequest.newBuilder().setValue(111972721).build();
* deprecatedServiceClient.slowFibonacci(request);
Expand All @@ -195,8 +213,11 @@ public class DeprecatedServiceClient implements BackgroundResource {
* Sample code:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* // This snippet has been automatically generated and should be regarded as a code template only.
* // It will require modifications to work:
* // - It may require correct/in-range values for request initialization.
* // - It may require specifying regional endpoints when creating the service client as shown in
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
* try (DeprecatedServiceClient deprecatedServiceClient = DeprecatedServiceClient.create()) {
* FibonacciRequest request = FibonacciRequest.newBuilder().setValue(111972721).build();
* ApiFuture<Empty> future = deprecatedServiceClient.slowFibonacciCallable().futureCall(request);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,11 @@ import javax.annotation.Generated;
* <p>For example, to set the total timeout of fastFibonacci to 30 seconds:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* // This snippet has been automatically generated and should be regarded as a code template only.
* // It will require modifications to work:
* // - It may require correct/in-range values for request initialization.
* // - It may require specifying regional endpoints when creating the service client as shown in
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
* DeprecatedServiceSettings.Builder deprecatedServiceSettingsBuilder =
* DeprecatedServiceSettings.newBuilder();
* deprecatedServiceSettingsBuilder
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,11 @@ import org.threeten.bp.Duration;
* <p>For example, to set the total timeout of fastFibonacci to 30 seconds:
*
* <pre>{@code
* // This snippet has been automatically generated for illustrative purposes only.
* // It may require modifications to work in your environment.
* // This snippet has been automatically generated and should be regarded as a code template only.
* // It will require modifications to work:
* // - It may require correct/in-range values for request initialization.
* // - It may require specifying regional endpoints when creating the service client as shown in
* // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
* DeprecatedServiceStubSettings.Builder deprecatedServiceSettingsBuilder =
* DeprecatedServiceStubSettings.newBuilder();
* deprecatedServiceSettingsBuilder
Expand Down
Loading