Class Generated.NetworkPolicyIngressRule.Builder

    • Method Detail

      • getDescriptor

        public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
      • internalGetFieldAccessorTable

        protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
        Specified by:
        internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3.Builder<Generated.NetworkPolicyIngressRule.Builder>
      • getDescriptorForType

        public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
        Specified by:
        getDescriptorForType in interface com.google.protobuf.Message.Builder
        Specified by:
        getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
        Overrides:
        getDescriptorForType in class com.google.protobuf.GeneratedMessageV3.Builder<Generated.NetworkPolicyIngressRule.Builder>
      • getDefaultInstanceForType

        public Generated.NetworkPolicyIngressRule getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
      • build

        public Generated.NetworkPolicyIngressRule build()
        Specified by:
        build in interface com.google.protobuf.Message.Builder
        Specified by:
        build in interface com.google.protobuf.MessageLite.Builder
      • buildPartial

        public Generated.NetworkPolicyIngressRule buildPartial()
        Specified by:
        buildPartial in interface com.google.protobuf.Message.Builder
        Specified by:
        buildPartial in interface com.google.protobuf.MessageLite.Builder
      • isInitialized

        public final boolean isInitialized()
        Specified by:
        isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
        Overrides:
        isInitialized in class com.google.protobuf.GeneratedMessageV3.Builder<Generated.NetworkPolicyIngressRule.Builder>
      • getPortsList

        public List<Generated.NetworkPolicyPort> getPortsList()
         ports is a list of ports which should be made accessible on the pods selected for
         this rule. 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.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPort ports = 1;
        Specified by:
        getPortsList in interface Generated.NetworkPolicyIngressRuleOrBuilder
      • getPortsCount

        public int getPortsCount()
         ports is a list of ports which should be made accessible on the pods selected for
         this rule. 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.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPort ports = 1;
        Specified by:
        getPortsCount in interface Generated.NetworkPolicyIngressRuleOrBuilder
      • getPorts

        public Generated.NetworkPolicyPort getPorts​(int index)
         ports is a list of ports which should be made accessible on the pods selected for
         this rule. 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.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPort ports = 1;
        Specified by:
        getPorts in interface Generated.NetworkPolicyIngressRuleOrBuilder
      • setPorts

        public Generated.NetworkPolicyIngressRule.Builder setPorts​(int index,
                                                                   Generated.NetworkPolicyPort value)
         ports is a list of ports which should be made accessible on the pods selected for
         this rule. 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.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPort ports = 1;
      • setPorts

        public Generated.NetworkPolicyIngressRule.Builder setPorts​(int index,
                                                                   Generated.NetworkPolicyPort.Builder builderForValue)
         ports is a list of ports which should be made accessible on the pods selected for
         this rule. 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.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPort ports = 1;
      • addPorts

        public Generated.NetworkPolicyIngressRule.Builder addPorts​(Generated.NetworkPolicyPort value)
         ports is a list of ports which should be made accessible on the pods selected for
         this rule. 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.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPort ports = 1;
      • addPorts

        public Generated.NetworkPolicyIngressRule.Builder addPorts​(int index,
                                                                   Generated.NetworkPolicyPort value)
         ports is a list of ports which should be made accessible on the pods selected for
         this rule. 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.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPort ports = 1;
      • addPorts

        public Generated.NetworkPolicyIngressRule.Builder addPorts​(Generated.NetworkPolicyPort.Builder builderForValue)
         ports is a list of ports which should be made accessible on the pods selected for
         this rule. 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.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPort ports = 1;
      • addPorts

        public Generated.NetworkPolicyIngressRule.Builder addPorts​(int index,
                                                                   Generated.NetworkPolicyPort.Builder builderForValue)
         ports is a list of ports which should be made accessible on the pods selected for
         this rule. 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.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPort ports = 1;
      • addAllPorts

        public Generated.NetworkPolicyIngressRule.Builder addAllPorts​(Iterable<? extends Generated.NetworkPolicyPort> values)
         ports is a list of ports which should be made accessible on the pods selected for
         this rule. 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.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPort ports = 1;
      • clearPorts

        public Generated.NetworkPolicyIngressRule.Builder clearPorts()
         ports is a list of ports which should be made accessible on the pods selected for
         this rule. 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.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPort ports = 1;
      • removePorts

        public Generated.NetworkPolicyIngressRule.Builder removePorts​(int index)
         ports is a list of ports which should be made accessible on the pods selected for
         this rule. 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.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPort ports = 1;
      • getPortsBuilder

        public Generated.NetworkPolicyPort.Builder getPortsBuilder​(int index)
         ports is a list of ports which should be made accessible on the pods selected for
         this rule. 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.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPort ports = 1;
      • getPortsOrBuilder

        public Generated.NetworkPolicyPortOrBuilder getPortsOrBuilder​(int index)
         ports is a list of ports which should be made accessible on the pods selected for
         this rule. 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.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPort ports = 1;
        Specified by:
        getPortsOrBuilder in interface Generated.NetworkPolicyIngressRuleOrBuilder
      • getPortsOrBuilderList

        public List<? extends Generated.NetworkPolicyPortOrBuilder> getPortsOrBuilderList()
         ports is a list of ports which should be made accessible on the pods selected for
         this rule. 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.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPort ports = 1;
        Specified by:
        getPortsOrBuilderList in interface Generated.NetworkPolicyIngressRuleOrBuilder
      • addPortsBuilder

        public Generated.NetworkPolicyPort.Builder addPortsBuilder()
         ports is a list of ports which should be made accessible on the pods selected for
         this rule. 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.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPort ports = 1;
      • addPortsBuilder

        public Generated.NetworkPolicyPort.Builder addPortsBuilder​(int index)
         ports is a list of ports which should be made accessible on the pods selected for
         this rule. 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.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPort ports = 1;
      • getPortsBuilderList

        public List<Generated.NetworkPolicyPort.Builder> getPortsBuilderList()
         ports is a list of ports which should be made accessible on the pods selected for
         this rule. 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.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPort ports = 1;
      • getFromList

        public List<Generated.NetworkPolicyPeer> getFromList()
         from is a list of sources which should be able to access the 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 sources (traffic not restricted by
         source). 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 from list.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPeer from = 2;
        Specified by:
        getFromList in interface Generated.NetworkPolicyIngressRuleOrBuilder
      • getFromCount

        public int getFromCount()
         from is a list of sources which should be able to access the 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 sources (traffic not restricted by
         source). 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 from list.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPeer from = 2;
        Specified by:
        getFromCount in interface Generated.NetworkPolicyIngressRuleOrBuilder
      • getFrom

        public Generated.NetworkPolicyPeer getFrom​(int index)
         from is a list of sources which should be able to access the 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 sources (traffic not restricted by
         source). 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 from list.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPeer from = 2;
        Specified by:
        getFrom in interface Generated.NetworkPolicyIngressRuleOrBuilder
      • setFrom

        public Generated.NetworkPolicyIngressRule.Builder setFrom​(int index,
                                                                  Generated.NetworkPolicyPeer value)
         from is a list of sources which should be able to access the 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 sources (traffic not restricted by
         source). 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 from list.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPeer from = 2;
      • setFrom

        public Generated.NetworkPolicyIngressRule.Builder setFrom​(int index,
                                                                  Generated.NetworkPolicyPeer.Builder builderForValue)
         from is a list of sources which should be able to access the 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 sources (traffic not restricted by
         source). 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 from list.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPeer from = 2;
      • addFrom

        public Generated.NetworkPolicyIngressRule.Builder addFrom​(Generated.NetworkPolicyPeer value)
         from is a list of sources which should be able to access the 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 sources (traffic not restricted by
         source). 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 from list.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPeer from = 2;
      • addFrom

        public Generated.NetworkPolicyIngressRule.Builder addFrom​(int index,
                                                                  Generated.NetworkPolicyPeer value)
         from is a list of sources which should be able to access the 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 sources (traffic not restricted by
         source). 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 from list.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPeer from = 2;
      • addFrom

        public Generated.NetworkPolicyIngressRule.Builder addFrom​(Generated.NetworkPolicyPeer.Builder builderForValue)
         from is a list of sources which should be able to access the 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 sources (traffic not restricted by
         source). 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 from list.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPeer from = 2;
      • addFrom

        public Generated.NetworkPolicyIngressRule.Builder addFrom​(int index,
                                                                  Generated.NetworkPolicyPeer.Builder builderForValue)
         from is a list of sources which should be able to access the 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 sources (traffic not restricted by
         source). 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 from list.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPeer from = 2;
      • addAllFrom

        public Generated.NetworkPolicyIngressRule.Builder addAllFrom​(Iterable<? extends Generated.NetworkPolicyPeer> values)
         from is a list of sources which should be able to access the 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 sources (traffic not restricted by
         source). 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 from list.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPeer from = 2;
      • clearFrom

        public Generated.NetworkPolicyIngressRule.Builder clearFrom()
         from is a list of sources which should be able to access the 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 sources (traffic not restricted by
         source). 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 from list.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPeer from = 2;
      • removeFrom

        public Generated.NetworkPolicyIngressRule.Builder removeFrom​(int index)
         from is a list of sources which should be able to access the 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 sources (traffic not restricted by
         source). 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 from list.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPeer from = 2;
      • getFromBuilder

        public Generated.NetworkPolicyPeer.Builder getFromBuilder​(int index)
         from is a list of sources which should be able to access the 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 sources (traffic not restricted by
         source). 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 from list.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPeer from = 2;
      • getFromOrBuilder

        public Generated.NetworkPolicyPeerOrBuilder getFromOrBuilder​(int index)
         from is a list of sources which should be able to access the 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 sources (traffic not restricted by
         source). 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 from list.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPeer from = 2;
        Specified by:
        getFromOrBuilder in interface Generated.NetworkPolicyIngressRuleOrBuilder
      • getFromOrBuilderList

        public List<? extends Generated.NetworkPolicyPeerOrBuilder> getFromOrBuilderList()
         from is a list of sources which should be able to access the 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 sources (traffic not restricted by
         source). 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 from list.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPeer from = 2;
        Specified by:
        getFromOrBuilderList in interface Generated.NetworkPolicyIngressRuleOrBuilder
      • addFromBuilder

        public Generated.NetworkPolicyPeer.Builder addFromBuilder()
         from is a list of sources which should be able to access the 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 sources (traffic not restricted by
         source). 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 from list.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPeer from = 2;
      • addFromBuilder

        public Generated.NetworkPolicyPeer.Builder addFromBuilder​(int index)
         from is a list of sources which should be able to access the 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 sources (traffic not restricted by
         source). 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 from list.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPeer from = 2;
      • getFromBuilderList

        public List<Generated.NetworkPolicyPeer.Builder> getFromBuilderList()
         from is a list of sources which should be able to access the 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 sources (traffic not restricted by
         source). 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 from list.
         +optional
         +listType=atomic
         
        repeated .k8s.io.api.networking.v1.NetworkPolicyPeer from = 2;