Class V1NetworkPolicyEgressRule
java.lang.Object
io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule
@Generated(value="org.openapitools.codegen.languages.JavaClientCodegen",
date="2024-02-02T21:37:40.170033Z[Etc/UTC]")
public class V1NetworkPolicyEgressRule
extends Object
NetworkPolicyEgressRule describes a particular set of traffic that is allowed out of pods matched by a NetworkPolicySpec's podSelector. The traffic must match both ports and to. This type is beta-level in 1.8
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionaddPortsItem
(V1NetworkPolicyPort portsItem) addToItem
(V1NetworkPolicyPeer toItem) boolean
getPorts()
ports is a list of destination ports for outgoing traffic.getTo()
to is a list of destinations for outgoing traffic of pods selected for this rule.int
hashCode()
ports
(List<V1NetworkPolicyPort> ports) void
setPorts
(List<V1NetworkPolicyPort> ports) void
setTo
(List<V1NetworkPolicyPeer> to) to
(List<V1NetworkPolicyPeer> to) toString()
-
Field Details
-
SERIALIZED_NAME_PORTS
- See Also:
-
SERIALIZED_NAME_TO
- See Also:
-
-
Constructor Details
-
V1NetworkPolicyEgressRule
public V1NetworkPolicyEgressRule()
-
-
Method Details
-
ports
-
addPortsItem
-
getPorts
ports is a list of destination ports for outgoing traffic. Each item in this list is combined using a logical OR. If this field is empty or missing, this rule matches all ports (traffic not restricted by port). If this field is present and contains at least one item, then this rule allows traffic only if the traffic matches at least one port in the list.- Returns:
- ports
-
setPorts
-
to
-
addToItem
-
getTo
to is a list of destinations for outgoing traffic of pods selected for this rule. Items in this list are combined using a logical OR operation. If this field is empty or missing, this rule matches all destinations (traffic not restricted by destination). If this field is present and contains at least one item, this rule allows traffic only if the traffic matches at least one item in the to list.- Returns:
- to
-
setTo
-
equals
-
hashCode
public int hashCode() -
toString
-