Class GatewaySecurityPolicyRule.Builder
java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<GatewaySecurityPolicyRule.Builder>
com.google.cloud.networksecurity.v1.GatewaySecurityPolicyRule.Builder
- All Implemented Interfaces:
GatewaySecurityPolicyRuleOrBuilder,com.google.protobuf.Message.Builder,com.google.protobuf.MessageLite.Builder,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,Cloneable
- Enclosing class:
- GatewaySecurityPolicyRule
public static final class GatewaySecurityPolicyRule.Builder
extends com.google.protobuf.GeneratedMessage.Builder<GatewaySecurityPolicyRule.Builder>
implements GatewaySecurityPolicyRuleOrBuilder
The GatewaySecurityPolicyRule resource is in a nested collection within a GatewaySecurityPolicy and represents a traffic matching condition and associated action to perform.Protobuf type
google.cloud.networksecurity.v1.GatewaySecurityPolicyRule-
Method Summary
Modifier and TypeMethodDescriptionbuild()clear()Optional.Required.Output only.Optional.Required.Required.Required.Required.Optional.Output only.Optional.com.google.protobuf.ByteStringOptional.Required.intRequired.com.google.protobuf.TimestampOutput only.com.google.protobuf.Timestamp.BuilderOutput only.com.google.protobuf.TimestampOrBuilderOutput only.Optional.com.google.protobuf.ByteStringOptional.static final com.google.protobuf.Descriptors.Descriptorcom.google.protobuf.Descriptors.DescriptorbooleanRequired.getName()Required.com.google.protobuf.ByteStringRequired.intRequired.Required.com.google.protobuf.ByteStringRequired.booleanOptional.com.google.protobuf.TimestampOutput only.com.google.protobuf.Timestamp.BuilderOutput only.com.google.protobuf.TimestampOrBuilderOutput only.booleanRequired.booleanOutput only.booleanOutput only.protected com.google.protobuf.GeneratedMessage.FieldAccessorTablefinal booleanmergeCreateTime(com.google.protobuf.Timestamp value) Output only.mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) mergeFrom(com.google.protobuf.Message other) mergeUpdateTime(com.google.protobuf.Timestamp value) Output only.setApplicationMatcher(String value) Optional.setApplicationMatcherBytes(com.google.protobuf.ByteString value) Optional.Required.setBasicProfileValue(int value) Required.setCreateTime(com.google.protobuf.Timestamp value) Output only.setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) Output only.setDescription(String value) Optional.setDescriptionBytes(com.google.protobuf.ByteString value) Optional.setEnabled(boolean value) Required.Required.setNameBytes(com.google.protobuf.ByteString value) Required.setPriority(int value) Required.setSessionMatcher(String value) Required.setSessionMatcherBytes(com.google.protobuf.ByteString value) Required.setTlsInspectionEnabled(boolean value) Optional.setUpdateTime(com.google.protobuf.Timestamp value) Output only.setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) Output only.Methods inherited from class com.google.protobuf.GeneratedMessage.Builder
addRepeatedField, clearField, clearOneof, clone, getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, internalGetMutableMapField, internalGetMutableMapFieldReflection, isClean, markClean, mergeUnknownFields, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setField, setRepeatedField, setUnknownFields, setUnknownFieldSetBuilder, setUnknownFieldsProto3Methods inherited from class com.google.protobuf.AbstractMessage.Builder
findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toStringMethods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageExceptionMethods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.protobuf.Message.Builder
mergeDelimitedFrom, mergeDelimitedFromMethods inherited from interface com.google.protobuf.MessageLite.Builder
mergeFromMethods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Method Details
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() -
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()- Specified by:
internalGetFieldAccessorTablein classcom.google.protobuf.GeneratedMessage.Builder<GatewaySecurityPolicyRule.Builder>
-
clear
- Specified by:
clearin interfacecom.google.protobuf.Message.Builder- Specified by:
clearin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
clearin classcom.google.protobuf.GeneratedMessage.Builder<GatewaySecurityPolicyRule.Builder>
-
getDescriptorForType
public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.Message.Builder- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.MessageOrBuilder- Overrides:
getDescriptorForTypein classcom.google.protobuf.GeneratedMessage.Builder<GatewaySecurityPolicyRule.Builder>
-
getDefaultInstanceForType
- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageLiteOrBuilder- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageOrBuilder
-
build
- Specified by:
buildin interfacecom.google.protobuf.Message.Builder- Specified by:
buildin interfacecom.google.protobuf.MessageLite.Builder
-
buildPartial
- Specified by:
buildPartialin interfacecom.google.protobuf.Message.Builder- Specified by:
buildPartialin interfacecom.google.protobuf.MessageLite.Builder
-
mergeFrom
- Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<GatewaySecurityPolicyRule.Builder>
-
mergeFrom
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessage.Builder<GatewaySecurityPolicyRule.Builder>
-
mergeFrom
public GatewaySecurityPolicyRule.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Specified by:
mergeFromin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<GatewaySecurityPolicyRule.Builder>- Throws:
IOException
-
getProfileCase
- Specified by:
getProfileCasein interfaceGatewaySecurityPolicyRuleOrBuilder
-
clearProfile
-
hasBasicProfile
public boolean hasBasicProfile()Required. Profile which tells what the primitive action should be.
.google.cloud.networksecurity.v1.GatewaySecurityPolicyRule.BasicProfile basic_profile = 9 [(.google.api.field_behavior) = REQUIRED];- Specified by:
hasBasicProfilein interfaceGatewaySecurityPolicyRuleOrBuilder- Returns:
- Whether the basicProfile field is set.
-
getBasicProfileValue
public int getBasicProfileValue()Required. Profile which tells what the primitive action should be.
.google.cloud.networksecurity.v1.GatewaySecurityPolicyRule.BasicProfile basic_profile = 9 [(.google.api.field_behavior) = REQUIRED];- Specified by:
getBasicProfileValuein interfaceGatewaySecurityPolicyRuleOrBuilder- Returns:
- The enum numeric value on the wire for basicProfile.
-
setBasicProfileValue
Required. Profile which tells what the primitive action should be.
.google.cloud.networksecurity.v1.GatewaySecurityPolicyRule.BasicProfile basic_profile = 9 [(.google.api.field_behavior) = REQUIRED];- Parameters:
value- The enum numeric value on the wire for basicProfile to set.- Returns:
- This builder for chaining.
-
getBasicProfile
Required. Profile which tells what the primitive action should be.
.google.cloud.networksecurity.v1.GatewaySecurityPolicyRule.BasicProfile basic_profile = 9 [(.google.api.field_behavior) = REQUIRED];- Specified by:
getBasicProfilein interfaceGatewaySecurityPolicyRuleOrBuilder- Returns:
- The basicProfile.
-
setBasicProfile
public GatewaySecurityPolicyRule.Builder setBasicProfile(GatewaySecurityPolicyRule.BasicProfile value) Required. Profile which tells what the primitive action should be.
.google.cloud.networksecurity.v1.GatewaySecurityPolicyRule.BasicProfile basic_profile = 9 [(.google.api.field_behavior) = REQUIRED];- Parameters:
value- The basicProfile to set.- Returns:
- This builder for chaining.
-
clearBasicProfile
Required. Profile which tells what the primitive action should be.
.google.cloud.networksecurity.v1.GatewaySecurityPolicyRule.BasicProfile basic_profile = 9 [(.google.api.field_behavior) = REQUIRED];- Returns:
- This builder for chaining.
-
getName
Required. Immutable. Name of the resource. ame is the full resource name so projects/{project}/locations/{location}/gatewaySecurityPolicies/{gateway_security_policy}/rules/{rule} rule should match the pattern: (^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$).string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];- Specified by:
getNamein interfaceGatewaySecurityPolicyRuleOrBuilder- Returns:
- The name.
-
getNameBytes
public com.google.protobuf.ByteString getNameBytes()Required. Immutable. Name of the resource. ame is the full resource name so projects/{project}/locations/{location}/gatewaySecurityPolicies/{gateway_security_policy}/rules/{rule} rule should match the pattern: (^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$).string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];- Specified by:
getNameBytesin interfaceGatewaySecurityPolicyRuleOrBuilder- Returns:
- The bytes for name.
-
setName
Required. Immutable. Name of the resource. ame is the full resource name so projects/{project}/locations/{location}/gatewaySecurityPolicies/{gateway_security_policy}/rules/{rule} rule should match the pattern: (^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$).string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];- Parameters:
value- The name to set.- Returns:
- This builder for chaining.
-
clearName
Required. Immutable. Name of the resource. ame is the full resource name so projects/{project}/locations/{location}/gatewaySecurityPolicies/{gateway_security_policy}/rules/{rule} rule should match the pattern: (^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$).string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];- Returns:
- This builder for chaining.
-
setNameBytes
Required. Immutable. Name of the resource. ame is the full resource name so projects/{project}/locations/{location}/gatewaySecurityPolicies/{gateway_security_policy}/rules/{rule} rule should match the pattern: (^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$).string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];- Parameters:
value- The bytes for name to set.- Returns:
- This builder for chaining.
-
hasCreateTime
public boolean hasCreateTime()Output only. Time when the rule was created.
.google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];- Specified by:
hasCreateTimein interfaceGatewaySecurityPolicyRuleOrBuilder- Returns:
- Whether the createTime field is set.
-
getCreateTime
public com.google.protobuf.Timestamp getCreateTime()Output only. Time when the rule was created.
.google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];- Specified by:
getCreateTimein interfaceGatewaySecurityPolicyRuleOrBuilder- Returns:
- The createTime.
-
setCreateTime
Output only. Time when the rule was created.
.google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; -
setCreateTime
public GatewaySecurityPolicyRule.Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) Output only. Time when the rule was created.
.google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; -
mergeCreateTime
Output only. Time when the rule was created.
.google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; -
clearCreateTime
Output only. Time when the rule was created.
.google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; -
getCreateTimeBuilder
public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder()Output only. Time when the rule was created.
.google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; -
getCreateTimeOrBuilder
public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder()Output only. Time when the rule was created.
.google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];- Specified by:
getCreateTimeOrBuilderin interfaceGatewaySecurityPolicyRuleOrBuilder
-
hasUpdateTime
public boolean hasUpdateTime()Output only. Time when the rule was updated.
.google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];- Specified by:
hasUpdateTimein interfaceGatewaySecurityPolicyRuleOrBuilder- Returns:
- Whether the updateTime field is set.
-
getUpdateTime
public com.google.protobuf.Timestamp getUpdateTime()Output only. Time when the rule was updated.
.google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];- Specified by:
getUpdateTimein interfaceGatewaySecurityPolicyRuleOrBuilder- Returns:
- The updateTime.
-
setUpdateTime
Output only. Time when the rule was updated.
.google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; -
setUpdateTime
public GatewaySecurityPolicyRule.Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) Output only. Time when the rule was updated.
.google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; -
mergeUpdateTime
Output only. Time when the rule was updated.
.google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; -
clearUpdateTime
Output only. Time when the rule was updated.
.google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; -
getUpdateTimeBuilder
public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder()Output only. Time when the rule was updated.
.google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; -
getUpdateTimeOrBuilder
public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder()Output only. Time when the rule was updated.
.google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];- Specified by:
getUpdateTimeOrBuilderin interfaceGatewaySecurityPolicyRuleOrBuilder
-
getEnabled
public boolean getEnabled()Required. Whether the rule is enforced.
bool enabled = 4 [(.google.api.field_behavior) = REQUIRED];- Specified by:
getEnabledin interfaceGatewaySecurityPolicyRuleOrBuilder- Returns:
- The enabled.
-
setEnabled
Required. Whether the rule is enforced.
bool enabled = 4 [(.google.api.field_behavior) = REQUIRED];- Parameters:
value- The enabled to set.- Returns:
- This builder for chaining.
-
clearEnabled
Required. Whether the rule is enforced.
bool enabled = 4 [(.google.api.field_behavior) = REQUIRED];- Returns:
- This builder for chaining.
-
getPriority
public int getPriority()Required. Priority of the rule. Lower number corresponds to higher precedence.
int32 priority = 5 [(.google.api.field_behavior) = REQUIRED];- Specified by:
getPriorityin interfaceGatewaySecurityPolicyRuleOrBuilder- Returns:
- The priority.
-
setPriority
Required. Priority of the rule. Lower number corresponds to higher precedence.
int32 priority = 5 [(.google.api.field_behavior) = REQUIRED];- Parameters:
value- The priority to set.- Returns:
- This builder for chaining.
-
clearPriority
Required. Priority of the rule. Lower number corresponds to higher precedence.
int32 priority = 5 [(.google.api.field_behavior) = REQUIRED];- Returns:
- This builder for chaining.
-
getDescription
Optional. Free-text description of the resource.
string description = 6 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getDescriptionin interfaceGatewaySecurityPolicyRuleOrBuilder- Returns:
- The description.
-
getDescriptionBytes
public com.google.protobuf.ByteString getDescriptionBytes()Optional. Free-text description of the resource.
string description = 6 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getDescriptionBytesin interfaceGatewaySecurityPolicyRuleOrBuilder- Returns:
- The bytes for description.
-
setDescription
Optional. Free-text description of the resource.
string description = 6 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The description to set.- Returns:
- This builder for chaining.
-
clearDescription
Optional. Free-text description of the resource.
string description = 6 [(.google.api.field_behavior) = OPTIONAL];- Returns:
- This builder for chaining.
-
setDescriptionBytes
Optional. Free-text description of the resource.
string description = 6 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The bytes for description to set.- Returns:
- This builder for chaining.
-
getSessionMatcher
Required. CEL expression for matching on session criteria.
string session_matcher = 7 [(.google.api.field_behavior) = REQUIRED];- Specified by:
getSessionMatcherin interfaceGatewaySecurityPolicyRuleOrBuilder- Returns:
- The sessionMatcher.
-
getSessionMatcherBytes
public com.google.protobuf.ByteString getSessionMatcherBytes()Required. CEL expression for matching on session criteria.
string session_matcher = 7 [(.google.api.field_behavior) = REQUIRED];- Specified by:
getSessionMatcherBytesin interfaceGatewaySecurityPolicyRuleOrBuilder- Returns:
- The bytes for sessionMatcher.
-
setSessionMatcher
Required. CEL expression for matching on session criteria.
string session_matcher = 7 [(.google.api.field_behavior) = REQUIRED];- Parameters:
value- The sessionMatcher to set.- Returns:
- This builder for chaining.
-
clearSessionMatcher
Required. CEL expression for matching on session criteria.
string session_matcher = 7 [(.google.api.field_behavior) = REQUIRED];- Returns:
- This builder for chaining.
-
setSessionMatcherBytes
public GatewaySecurityPolicyRule.Builder setSessionMatcherBytes(com.google.protobuf.ByteString value) Required. CEL expression for matching on session criteria.
string session_matcher = 7 [(.google.api.field_behavior) = REQUIRED];- Parameters:
value- The bytes for sessionMatcher to set.- Returns:
- This builder for chaining.
-
getApplicationMatcher
Optional. CEL expression for matching on L7/application level criteria.
string application_matcher = 8 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getApplicationMatcherin interfaceGatewaySecurityPolicyRuleOrBuilder- Returns:
- The applicationMatcher.
-
getApplicationMatcherBytes
public com.google.protobuf.ByteString getApplicationMatcherBytes()Optional. CEL expression for matching on L7/application level criteria.
string application_matcher = 8 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getApplicationMatcherBytesin interfaceGatewaySecurityPolicyRuleOrBuilder- Returns:
- The bytes for applicationMatcher.
-
setApplicationMatcher
Optional. CEL expression for matching on L7/application level criteria.
string application_matcher = 8 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The applicationMatcher to set.- Returns:
- This builder for chaining.
-
clearApplicationMatcher
Optional. CEL expression for matching on L7/application level criteria.
string application_matcher = 8 [(.google.api.field_behavior) = OPTIONAL];- Returns:
- This builder for chaining.
-
setApplicationMatcherBytes
public GatewaySecurityPolicyRule.Builder setApplicationMatcherBytes(com.google.protobuf.ByteString value) Optional. CEL expression for matching on L7/application level criteria.
string application_matcher = 8 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The bytes for applicationMatcher to set.- Returns:
- This builder for chaining.
-
getTlsInspectionEnabled
public boolean getTlsInspectionEnabled()Optional. Flag to enable TLS inspection of traffic matching on <session_matcher>, can only be true if the parent GatewaySecurityPolicy references a TLSInspectionConfig.
bool tls_inspection_enabled = 10 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getTlsInspectionEnabledin interfaceGatewaySecurityPolicyRuleOrBuilder- Returns:
- The tlsInspectionEnabled.
-
setTlsInspectionEnabled
Optional. Flag to enable TLS inspection of traffic matching on <session_matcher>, can only be true if the parent GatewaySecurityPolicy references a TLSInspectionConfig.
bool tls_inspection_enabled = 10 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The tlsInspectionEnabled to set.- Returns:
- This builder for chaining.
-
clearTlsInspectionEnabled
Optional. Flag to enable TLS inspection of traffic matching on <session_matcher>, can only be true if the parent GatewaySecurityPolicy references a TLSInspectionConfig.
bool tls_inspection_enabled = 10 [(.google.api.field_behavior) = OPTIONAL];- Returns:
- This builder for chaining.
-