public static final class CreateAlertPolicyRequest.Builder extends GeneratedMessageV3.Builder<CreateAlertPolicyRequest.Builder> implements CreateAlertPolicyRequestOrBuilder
The protocol for the CreateAlertPolicy
request.
Protobuf type google.monitoring.v3.CreateAlertPolicyRequest
Inherited Members
com.google.protobuf.GeneratedMessageV3.Builder.getUnknownFieldSetBuilder()
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownLengthDelimitedField(int,com.google.protobuf.ByteString)
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownVarintField(int,int)
com.google.protobuf.GeneratedMessageV3.Builder.parseUnknownField(com.google.protobuf.CodedInputStream,com.google.protobuf.ExtensionRegistryLite,int)
com.google.protobuf.GeneratedMessageV3.Builder.setUnknownFieldSetBuilder(com.google.protobuf.UnknownFieldSet.Builder)
Static Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Methods
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
public CreateAlertPolicyRequest.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Overrides
build()
public CreateAlertPolicyRequest build()
buildPartial()
public CreateAlertPolicyRequest buildPartial()
clear()
public CreateAlertPolicyRequest.Builder clear()
Overrides
clearAlertPolicy()
public CreateAlertPolicyRequest.Builder clearAlertPolicy()
Required. The requested alerting policy. You should omit the name
field
in this policy. The name will be returned in the new policy, including a
new [ALERT_POLICY_ID]
value.
.google.monitoring.v3.AlertPolicy alert_policy = 2 [(.google.api.field_behavior) = REQUIRED];
clearField(Descriptors.FieldDescriptor field)
public CreateAlertPolicyRequest.Builder clearField(Descriptors.FieldDescriptor field)
Overrides
clearName()
public CreateAlertPolicyRequest.Builder clearName()
Required. The
project in which
to create the alerting policy. The format is:
projects/[PROJECT_ID_OR_NUMBER]
Note that this field names the parent container in which the alerting
policy will be written, not the name of the created policy. |name| must be
a host project of a Metrics Scope, otherwise INVALID_ARGUMENT error will
return. The alerting policy that is returned will have a name that contains
a normalized representation of this name as a prefix but adds a suffix of
the form /alertPolicies/[ALERT_POLICY_ID]
, identifying the policy in the
container.
string name = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
clearOneof(Descriptors.OneofDescriptor oneof)
public CreateAlertPolicyRequest.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Overrides
clone()
public CreateAlertPolicyRequest.Builder clone()
Overrides
getAlertPolicy()
public AlertPolicy getAlertPolicy()
Required. The requested alerting policy. You should omit the name
field
in this policy. The name will be returned in the new policy, including a
new [ALERT_POLICY_ID]
value.
.google.monitoring.v3.AlertPolicy alert_policy = 2 [(.google.api.field_behavior) = REQUIRED];
getAlertPolicyBuilder()
public AlertPolicy.Builder getAlertPolicyBuilder()
Required. The requested alerting policy. You should omit the name
field
in this policy. The name will be returned in the new policy, including a
new [ALERT_POLICY_ID]
value.
.google.monitoring.v3.AlertPolicy alert_policy = 2 [(.google.api.field_behavior) = REQUIRED];
getAlertPolicyOrBuilder()
public AlertPolicyOrBuilder getAlertPolicyOrBuilder()
Required. The requested alerting policy. You should omit the name
field
in this policy. The name will be returned in the new policy, including a
new [ALERT_POLICY_ID]
value.
.google.monitoring.v3.AlertPolicy alert_policy = 2 [(.google.api.field_behavior) = REQUIRED];
getDefaultInstanceForType()
public CreateAlertPolicyRequest getDefaultInstanceForType()
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()
Overrides
getName()
Required. The
project in which
to create the alerting policy. The format is:
projects/[PROJECT_ID_OR_NUMBER]
Note that this field names the parent container in which the alerting
policy will be written, not the name of the created policy. |name| must be
a host project of a Metrics Scope, otherwise INVALID_ARGUMENT error will
return. The alerting policy that is returned will have a name that contains
a normalized representation of this name as a prefix but adds a suffix of
the form /alertPolicies/[ALERT_POLICY_ID]
, identifying the policy in the
container.
string name = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
Returns |
---|
Type | Description |
String | The name.
|
getNameBytes()
public ByteString getNameBytes()
Required. The
project in which
to create the alerting policy. The format is:
projects/[PROJECT_ID_OR_NUMBER]
Note that this field names the parent container in which the alerting
policy will be written, not the name of the created policy. |name| must be
a host project of a Metrics Scope, otherwise INVALID_ARGUMENT error will
return. The alerting policy that is returned will have a name that contains
a normalized representation of this name as a prefix but adds a suffix of
the form /alertPolicies/[ALERT_POLICY_ID]
, identifying the policy in the
container.
string name = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
Returns |
---|
Type | Description |
ByteString | The bytes for name.
|
hasAlertPolicy()
public boolean hasAlertPolicy()
Required. The requested alerting policy. You should omit the name
field
in this policy. The name will be returned in the new policy, including a
new [ALERT_POLICY_ID]
value.
.google.monitoring.v3.AlertPolicy alert_policy = 2 [(.google.api.field_behavior) = REQUIRED];
Returns |
---|
Type | Description |
boolean | Whether the alertPolicy field is set.
|
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Overrides
isInitialized()
public final boolean isInitialized()
Overrides
mergeAlertPolicy(AlertPolicy value)
public CreateAlertPolicyRequest.Builder mergeAlertPolicy(AlertPolicy value)
Required. The requested alerting policy. You should omit the name
field
in this policy. The name will be returned in the new policy, including a
new [ALERT_POLICY_ID]
value.
.google.monitoring.v3.AlertPolicy alert_policy = 2 [(.google.api.field_behavior) = REQUIRED];
mergeFrom(CreateAlertPolicyRequest other)
public CreateAlertPolicyRequest.Builder mergeFrom(CreateAlertPolicyRequest other)
public CreateAlertPolicyRequest.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Overrides
mergeFrom(Message other)
public CreateAlertPolicyRequest.Builder mergeFrom(Message other)
Parameter |
---|
Name | Description |
other | Message
|
Overrides
mergeUnknownFields(UnknownFieldSet unknownFields)
public final CreateAlertPolicyRequest.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Overrides
setAlertPolicy(AlertPolicy value)
public CreateAlertPolicyRequest.Builder setAlertPolicy(AlertPolicy value)
Required. The requested alerting policy. You should omit the name
field
in this policy. The name will be returned in the new policy, including a
new [ALERT_POLICY_ID]
value.
.google.monitoring.v3.AlertPolicy alert_policy = 2 [(.google.api.field_behavior) = REQUIRED];
setAlertPolicy(AlertPolicy.Builder builderForValue)
public CreateAlertPolicyRequest.Builder setAlertPolicy(AlertPolicy.Builder builderForValue)
Required. The requested alerting policy. You should omit the name
field
in this policy. The name will be returned in the new policy, including a
new [ALERT_POLICY_ID]
value.
.google.monitoring.v3.AlertPolicy alert_policy = 2 [(.google.api.field_behavior) = REQUIRED];
setField(Descriptors.FieldDescriptor field, Object value)
public CreateAlertPolicyRequest.Builder setField(Descriptors.FieldDescriptor field, Object value)
Overrides
setName(String value)
public CreateAlertPolicyRequest.Builder setName(String value)
Required. The
project in which
to create the alerting policy. The format is:
projects/[PROJECT_ID_OR_NUMBER]
Note that this field names the parent container in which the alerting
policy will be written, not the name of the created policy. |name| must be
a host project of a Metrics Scope, otherwise INVALID_ARGUMENT error will
return. The alerting policy that is returned will have a name that contains
a normalized representation of this name as a prefix but adds a suffix of
the form /alertPolicies/[ALERT_POLICY_ID]
, identifying the policy in the
container.
string name = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
Parameter |
---|
Name | Description |
value | String
The name to set.
|
setNameBytes(ByteString value)
public CreateAlertPolicyRequest.Builder setNameBytes(ByteString value)
Required. The
project in which
to create the alerting policy. The format is:
projects/[PROJECT_ID_OR_NUMBER]
Note that this field names the parent container in which the alerting
policy will be written, not the name of the created policy. |name| must be
a host project of a Metrics Scope, otherwise INVALID_ARGUMENT error will
return. The alerting policy that is returned will have a name that contains
a normalized representation of this name as a prefix but adds a suffix of
the form /alertPolicies/[ALERT_POLICY_ID]
, identifying the policy in the
container.
string name = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
Parameter |
---|
Name | Description |
value | ByteString
The bytes for name to set.
|
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
public CreateAlertPolicyRequest.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Overrides
setUnknownFields(UnknownFieldSet unknownFields)
public final CreateAlertPolicyRequest.Builder setUnknownFields(UnknownFieldSet unknownFields)
Overrides