Package com.ibm.cloud.is.vpc.v1.model
Class SecurityGroupRule
- java.lang.Object
-
- com.ibm.cloud.sdk.core.service.model.GenericModel
-
- com.ibm.cloud.is.vpc.v1.model.SecurityGroupRule
-
- All Implemented Interfaces:
com.ibm.cloud.sdk.core.service.model.ObjectModel
- Direct Known Subclasses:
SecurityGroupRuleSecurityGroupRuleProtocolAll,SecurityGroupRuleSecurityGroupRuleProtocolICMP,SecurityGroupRuleSecurityGroupRuleProtocolTCPUDP
public class SecurityGroupRule extends com.ibm.cloud.sdk.core.service.model.GenericModelSecurityGroupRule. Classes which extend this class: - SecurityGroupRuleSecurityGroupRuleProtocolAll - SecurityGroupRuleSecurityGroupRuleProtocolICMP - SecurityGroupRuleSecurityGroupRuleProtocolTCPUDP
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interfaceSecurityGroupRule.DirectionThe direction of traffic to enforce.static interfaceSecurityGroupRule.IpVersionThe IP version to enforce.static interfaceSecurityGroupRule.ProtocolThe protocol to enforce.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description LonggetCode()Gets the code.StringgetDirection()Gets the direction.StringgetHref()Gets the href.StringgetId()Gets the id.StringgetIpVersion()Gets the ipVersion.LonggetPortMax()Gets the portMax.LonggetPortMin()Gets the portMin.StringgetProtocol()Gets the protocol.SecurityGroupRuleRemotegetRemote()Gets the remote.LonggetType()Gets the type.
-
-
-
Method Detail
-
getDirection
public String getDirection()
Gets the direction. The direction of traffic to enforce.- Returns:
- the direction
-
getHref
public String getHref()
Gets the href. The URL for this security group rule.- Returns:
- the href
-
getId
public String getId()
Gets the id. The unique identifier for this security group rule.- Returns:
- the id
-
getIpVersion
public String getIpVersion()
Gets the ipVersion. The IP version to enforce. The format of `remote.address` or `remote.cidr_block` must match this property, if they are used. Alternatively, if `remote` references a security group, then this rule only applies to IP addresses (network interfaces) in that group matching this IP version.- Returns:
- the ipVersion
-
getProtocol
public String getProtocol()
Gets the protocol. The protocol to enforce.- Returns:
- the protocol
-
getRemote
public SecurityGroupRuleRemote getRemote()
Gets the remote. The remote IP addresses or security groups from which this rule allows traffic (or to which, for outbound rules). A CIDR block of `0.0.0.0/0` allows traffic from any source (or to any destination, for outbound rules).- Returns:
- the remote
-
getCode
public Long getCode()
Gets the code. The ICMP traffic code to allow. If absent, all codes are allowed.- Returns:
- the code
-
getType
public Long getType()
Gets the type. The ICMP traffic type to allow. If absent, all types are allowed.- Returns:
- the type
-
getPortMax
public Long getPortMax()
Gets the portMax. The inclusive upper bound of TCP/UDP destination port range.- Returns:
- the portMax
-
getPortMin
public Long getPortMin()
Gets the portMin. The inclusive lower bound of TCP/UDP destination port range.- Returns:
- the portMin
-
-