/** * * * <pre> * Required. The new exclusion, whose `name` parameter is an exclusion name * that is not already used in the parent resource. * </pre> * * <code>.google.logging.v2.LogExclusion exclusion = 2;</code> */ private com.google.protobuf.SingleFieldBuilderV3< com.google.logging.v2.LogExclusion, com.google.logging.v2.LogExclusion.Builder, com.google.logging.v2.LogExclusionOrBuilder> getExclusionFieldBuilder() { if (exclusionBuilder_ == null) { exclusionBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.logging.v2.LogExclusion, com.google.logging.v2.LogExclusion.Builder, com.google.logging.v2.LogExclusionOrBuilder>( getExclusion(), getParentForChildren(), isClean()); exclusion_ = null; } return exclusionBuilder_; }
/** * * * <pre> * Required. The new exclusion, whose `name` parameter is an exclusion name * that is not already used in the parent resource. * </pre> * * <code>.google.logging.v2.LogExclusion exclusion = 2;</code> */ public com.google.logging.v2.LogExclusion.Builder getExclusionBuilder() { onChanged(); return getExclusionFieldBuilder().getBuilder(); } /**
@java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { com.google.logging.v2.CreateExclusionRequest parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (com.google.logging.v2.CreateExclusionRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; }
/** * Creates a new exclusion in a specified parent resource. Only log entries belonging to that * resource can be excluded. You can have up to 10 exclusions in a resource. * * <p>Sample code: * * <pre><code> * try (ConfigClient configClient = ConfigClient.create()) { * ParentName parent = ProjectName.of("[PROJECT]"); * LogExclusion exclusion = LogExclusion.newBuilder().build(); * LogExclusion response = configClient.createExclusion(parent, exclusion); * } * </code></pre> * * @param parent Required. The parent resource in which to create the exclusion: * <p>"projects/[PROJECT_ID]" "organizations/[ORGANIZATION_ID]" * "billingAccounts/[BILLING_ACCOUNT_ID]" "folders/[FOLDER_ID]" * <p>Examples: `"projects/my-logging-project"`, `"organizations/123456789"`. * @param exclusion Required. The new exclusion, whose `name` parameter is an exclusion name that * is not already used in the parent resource. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final LogExclusion createExclusion(ParentName parent, LogExclusion exclusion) { CreateExclusionRequest request = CreateExclusionRequest.newBuilder() .setParent(parent == null ? null : parent.toString()) .setExclusion(exclusion) .build(); return createExclusion(request); }
/** * Creates a new exclusion in a specified parent resource. Only log entries belonging to that * resource can be excluded. You can have up to 10 exclusions in a resource. * * <p>Sample code: * * <pre><code> * try (ConfigClient configClient = ConfigClient.create()) { * ParentName parent = ProjectName.of("[PROJECT]"); * LogExclusion exclusion = LogExclusion.newBuilder().build(); * LogExclusion response = configClient.createExclusion(parent.toString(), exclusion); * } * </code></pre> * * @param parent Required. The parent resource in which to create the exclusion: * <p>"projects/[PROJECT_ID]" "organizations/[ORGANIZATION_ID]" * "billingAccounts/[BILLING_ACCOUNT_ID]" "folders/[FOLDER_ID]" * <p>Examples: `"projects/my-logging-project"`, `"organizations/123456789"`. * @param exclusion Required. The new exclusion, whose `name` parameter is an exclusion name that * is not already used in the parent resource. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final LogExclusion createExclusion(String parent, LogExclusion exclusion) { CreateExclusionRequest request = CreateExclusionRequest.newBuilder().setParent(parent).setExclusion(exclusion).build(); return createExclusion(request); }
/** * Creates a new exclusion in a specified parent resource. Only log entries belonging to that * resource can be excluded. You can have up to 10 exclusions in a resource. * * <p>Sample code: * * <pre><code> * try (ConfigClient configClient = ConfigClient.create()) { * ParentName parent = ProjectName.of("[PROJECT]"); * LogExclusion exclusion = LogExclusion.newBuilder().build(); * LogExclusion response = configClient.createExclusion(parent, exclusion); * } * </code></pre> * * @param parent Required. The parent resource in which to create the exclusion: * <p>"projects/[PROJECT_ID]" "organizations/[ORGANIZATION_ID]" * "billingAccounts/[BILLING_ACCOUNT_ID]" "folders/[FOLDER_ID]" * <p>Examples: `"projects/my-logging-project"`, `"organizations/123456789"`. * @param exclusion Required. The new exclusion, whose `name` parameter is an exclusion name that * is not already used in the parent resource. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final LogExclusion createExclusion(ParentName parent, LogExclusion exclusion) { CreateExclusionRequest request = CreateExclusionRequest.newBuilder() .setParent(parent == null ? null : parent.toString()) .setExclusion(exclusion) .build(); return createExclusion(request); }
/** * Creates a new exclusion in a specified parent resource. Only log entries belonging to that * resource can be excluded. You can have up to 10 exclusions in a resource. * * <p>Sample code: * * <pre><code> * try (ConfigClient configClient = ConfigClient.create()) { * ParentName parent = ProjectName.of("[PROJECT]"); * LogExclusion exclusion = LogExclusion.newBuilder().build(); * LogExclusion response = configClient.createExclusion(parent.toString(), exclusion); * } * </code></pre> * * @param parent Required. The parent resource in which to create the exclusion: * <p>"projects/[PROJECT_ID]" "organizations/[ORGANIZATION_ID]" * "billingAccounts/[BILLING_ACCOUNT_ID]" "folders/[FOLDER_ID]" * <p>Examples: `"projects/my-logging-project"`, `"organizations/123456789"`. * @param exclusion Required. The new exclusion, whose `name` parameter is an exclusion name that * is not already used in the parent resource. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final LogExclusion createExclusion(String parent, LogExclusion exclusion) { CreateExclusionRequest request = CreateExclusionRequest.newBuilder().setParent(parent).setExclusion(exclusion).build(); return createExclusion(request); }
public static Builder newBuilder(com.google.logging.v2.CreateExclusionRequest prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); }
private Builder() { maybeForceBuilderInitialization(); }
public Builder mergeFrom(com.google.logging.v2.CreateExclusionRequest other) { if (other == com.google.logging.v2.CreateExclusionRequest.getDefaultInstance()) return this; if (!other.getParent().isEmpty()) { parent_ = other.parent_; onChanged(); } if (other.hasExclusion()) { mergeExclusion(other.getExclusion()); } this.mergeUnknownFields(other.unknownFields); onChanged(); return this; }
@java.lang.Override protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /**
private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); }
@java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.logging.v2.CreateExclusionRequest) { return mergeFrom((com.google.logging.v2.CreateExclusionRequest) other); } else { super.mergeFrom(other); return this; } }
@java.lang.Override public com.google.logging.v2.CreateExclusionRequest build() { com.google.logging.v2.CreateExclusionRequest result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; }