Class SecurityGroupRulePatch
java.lang.Object
com.ibm.cloud.sdk.core.service.model.GenericModel
com.ibm.cloud.is.vpc.v1.model.SecurityGroupRulePatch
- All Implemented Interfaces:
com.ibm.cloud.sdk.core.service.model.ObjectModel
public class SecurityGroupRulePatch
extends com.ibm.cloud.sdk.core.service.model.GenericModel
SecurityGroupRulePatch.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic class
Builder.static interface
The direction of traffic to allow.static interface
The IP version to allow. -
Method Summary
Modifier and TypeMethodDescriptionasPatch()
Construct a JSON merge-patch from the SecurityGroupRulePatch.code()
Gets the code.Gets the direction.Gets the ipVersion.local()
Gets the local.New builder.portMax()
Gets the portMax.portMin()
Gets the portMin.remote()
Gets the remote.type()
Gets the type.Methods inherited from class com.ibm.cloud.sdk.core.service.model.GenericModel
equals, hashCode, toString
-
Method Details
-
newBuilder
New builder.- Returns:
- a SecurityGroupRulePatch builder
-
code
Gets the code. The ICMP traffic code to allow. If set, `type` must also be set. Specify `null` to remove an existing ICMP traffic code.- Returns:
- the code
-
direction
Gets the direction. The direction of traffic to allow.- Returns:
- the direction
-
ipVersion
Gets the ipVersion. The IP version to allow. The format of `local.address`, `remote.address`, `local.cidr_block` or `remote.cidr_block` must match this property, if they are used. If `remote` references a security group, then this rule only applies to IP addresses in that group matching this IP version.- Returns:
- the ipVersion
-
local
Gets the local. The local IP address or range of local IP addresses to which this rule will allow inbound traffic (or from which, for outbound traffic). Can be specified as an IP address or a CIDR block. Specify a CIDR block of `0.0.0.0/0` to allow traffic to all local IP addresses (or from all local IP addresses, for outbound rules).- Returns:
- the local
-
portMax
Gets the portMax. The inclusive upper bound of the protocol destination port range. If set, `port_min` must also be set, and must not be larger. Specify `null` to remove an existing upper bound.- Returns:
- the portMax
-
portMin
Gets the portMin. The inclusive lower bound of the protocol destination port range. If set, `port_max` must also be set, and must not be smaller. Specify `null` to remove an existing lower bound.- Returns:
- the portMin
-
remote
Gets the remote. The remote IP addresses or security groups from which this rule will allow traffic (or to which, for outbound rules). Can be specified as an IP address, a CIDR block, or a security group. A CIDR block of `0.0.0.0/0` will allow traffic from any source (or to any destination, for outbound rules).- Returns:
- the remote
-
type
Gets the type. The ICMP traffic type to allow. Specify `null` to remove an existing ICMP traffic type value.- Returns:
- the type
-
asPatch
Construct a JSON merge-patch from the SecurityGroupRulePatch. Note that properties of the SecurityGroupRulePatch with null values are not represented in the constructed JSON merge-patch object, but can be explicitly set afterward to signify a property delete.- Returns:
- a JSON merge-patch for the SecurityGroupRulePatch
-