public Builder mergeFrom(com.google.logging.v2.ListExclusionsRequest other) { if (other == com.google.logging.v2.ListExclusionsRequest.getDefaultInstance()) return this; if (!other.getParent().isEmpty()) { parent_ = other.parent_; onChanged(); } if (!other.getPageToken().isEmpty()) { pageToken_ = other.pageToken_; onChanged(); } if (other.getPageSize() != 0) { setPageSize(other.getPageSize()); } this.mergeUnknownFields(other.unknownFields); onChanged(); return this; }
/** * Lists all the exclusions in a parent resource. * * <p>Sample code: * * <pre><code> * try (ConfigClient configClient = ConfigClient.create()) { * ParentName parent = ProjectName.of("[PROJECT]"); * for (LogExclusion element : configClient.listExclusions(parent).iterateAll()) { * // doThingsWith(element); * } * } * </code></pre> * * @param parent Required. The parent resource whose exclusions are to be listed. * <p>"projects/[PROJECT_ID]" "organizations/[ORGANIZATION_ID]" * "billingAccounts/[BILLING_ACCOUNT_ID]" "folders/[FOLDER_ID]" * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final ListExclusionsPagedResponse listExclusions(ParentName parent) { ListExclusionsRequest request = ListExclusionsRequest.newBuilder() .setParent(parent == null ? null : parent.toString()) .build(); return listExclusions(request); }
@java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { com.google.logging.v2.ListExclusionsRequest parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (com.google.logging.v2.ListExclusionsRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; }
/** * Lists all the exclusions in a parent resource. * * <p>Sample code: * * <pre><code> * try (ConfigClient configClient = ConfigClient.create()) { * ParentName parent = ProjectName.of("[PROJECT]"); * for (LogExclusion element : configClient.listExclusions(parent).iterateAll()) { * // doThingsWith(element); * } * } * </code></pre> * * @param parent Required. The parent resource whose exclusions are to be listed. * <p>"projects/[PROJECT_ID]" "organizations/[ORGANIZATION_ID]" * "billingAccounts/[BILLING_ACCOUNT_ID]" "folders/[FOLDER_ID]" * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final ListExclusionsPagedResponse listExclusions(ParentName parent) { ListExclusionsRequest request = ListExclusionsRequest.newBuilder() .setParent(parent == null ? null : parent.toString()) .build(); return listExclusions(request); }
/** * Lists all the exclusions in a parent resource. * * <p>Sample code: * * <pre><code> * try (ConfigClient configClient = ConfigClient.create()) { * ParentName parent = ProjectName.of("[PROJECT]"); * for (LogExclusion element : configClient.listExclusions(parent.toString()).iterateAll()) { * // doThingsWith(element); * } * } * </code></pre> * * @param parent Required. The parent resource whose exclusions are to be listed. * <p>"projects/[PROJECT_ID]" "organizations/[ORGANIZATION_ID]" * "billingAccounts/[BILLING_ACCOUNT_ID]" "folders/[FOLDER_ID]" * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final ListExclusionsPagedResponse listExclusions(String parent) { ListExclusionsRequest request = ListExclusionsRequest.newBuilder().setParent(parent).build(); return listExclusions(request); }
@Override public ListExclusionsRequest injectToken(ListExclusionsRequest payload, String token) { return ListExclusionsRequest.newBuilder(payload).setPageToken(token).build(); }
@Override public ListExclusionsRequest injectPageSize( ListExclusionsRequest payload, int pageSize) { return ListExclusionsRequest.newBuilder(payload).setPageSize(pageSize).build(); }
/** * Lists all the exclusions in a parent resource. * * <p>Sample code: * * <pre><code> * try (ConfigClient configClient = ConfigClient.create()) { * ParentName parent = ProjectName.of("[PROJECT]"); * for (LogExclusion element : configClient.listExclusions(parent.toString()).iterateAll()) { * // doThingsWith(element); * } * } * </code></pre> * * @param parent Required. The parent resource whose exclusions are to be listed. * <p>"projects/[PROJECT_ID]" "organizations/[ORGANIZATION_ID]" * "billingAccounts/[BILLING_ACCOUNT_ID]" "folders/[FOLDER_ID]" * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final ListExclusionsPagedResponse listExclusions(String parent) { ListExclusionsRequest request = ListExclusionsRequest.newBuilder().setParent(parent).build(); return listExclusions(request); }
/** * * * <pre> * Optional. If present, then retrieve the next batch of results from the * preceding call to this method. `pageToken` must be the value of * `nextPageToken` from the previous response. The values of other method * parameters should be identical to those in the previous call. * </pre> * * <code>string page_token = 2;</code> */ public Builder setPageToken(java.lang.String value) { if (value == null) { throw new NullPointerException(); } pageToken_ = value; onChanged(); return this; } /**
/** * * * <pre> * Required. The parent resource whose exclusions are to be listed. * "projects/[PROJECT_ID]" * "organizations/[ORGANIZATION_ID]" * "billingAccounts/[BILLING_ACCOUNT_ID]" * "folders/[FOLDER_ID]" * </pre> * * <code>string parent = 1;</code> */ public Builder setParentBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); parent_ = value; onChanged(); return this; }
/** * * * <pre> * Required. The parent resource whose exclusions are to be listed. * "projects/[PROJECT_ID]" * "organizations/[ORGANIZATION_ID]" * "billingAccounts/[BILLING_ACCOUNT_ID]" * "folders/[FOLDER_ID]" * </pre> * * <code>string parent = 1;</code> */ public Builder setParent(java.lang.String value) { if (value == null) { throw new NullPointerException(); } parent_ = value; onChanged(); return this; } /**
/** * * * <pre> * Optional. If present, then retrieve the next batch of results from the * preceding call to this method. `pageToken` must be the value of * `nextPageToken` from the previous response. The values of other method * parameters should be identical to those in the previous call. * </pre> * * <code>string page_token = 2;</code> */ public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); pageToken_ = value; onChanged(); return this; }
/** * * * <pre> * Optional. If present, then retrieve the next batch of results from the * preceding call to this method. `pageToken` must be the value of * `nextPageToken` from the previous response. The values of other method * parameters should be identical to those in the previous call. * </pre> * * <code>string page_token = 2;</code> */ public Builder clearPageToken() { pageToken_ = getDefaultInstance().getPageToken(); onChanged(); return this; } /**
/** * * * <pre> * Required. The parent resource whose exclusions are to be listed. * "projects/[PROJECT_ID]" * "organizations/[ORGANIZATION_ID]" * "billingAccounts/[BILLING_ACCOUNT_ID]" * "folders/[FOLDER_ID]" * </pre> * * <code>string parent = 1;</code> */ public Builder clearParent() { parent_ = getDefaultInstance().getParent(); onChanged(); return this; } /**
/** * * * <pre> * Optional. The maximum number of results to return from this request. * Non-positive values are ignored. The presence of `nextPageToken` in the * response indicates that more results might be available. * </pre> * * <code>int32 page_size = 3;</code> */ public Builder setPageSize(int value) { pageSize_ = value; onChanged(); return this; } /**
/** * * * <pre> * Optional. The maximum number of results to return from this request. * Non-positive values are ignored. The presence of `nextPageToken` in the * response indicates that more results might be available. * </pre> * * <code>int32 page_size = 3;</code> */ public Builder clearPageSize() { pageSize_ = 0; onChanged(); return this; }
private Builder() { maybeForceBuilderInitialization(); }
public static Builder newBuilder(com.google.logging.v2.ListExclusionsRequest prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); }
@java.lang.Override public com.google.logging.v2.ListExclusionsRequest buildPartial() { com.google.logging.v2.ListExclusionsRequest result = new com.google.logging.v2.ListExclusionsRequest(this); result.parent_ = parent_; result.pageToken_ = pageToken_; result.pageSize_ = pageSize_; onBuilt(); return result; }