Class IPMatcher.IPRangeMatcher

java.lang.Object
com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessage
com.google.protobuf.GeneratedMessageV3
com.github.xds.type.matcher.v3.IPMatcher.IPRangeMatcher
All Implemented Interfaces:
IPMatcher.IPRangeMatcherOrBuilder, com.google.protobuf.Message, com.google.protobuf.MessageLite, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Serializable
Enclosing class:
IPMatcher

public static final class IPMatcher.IPRangeMatcher extends com.google.protobuf.GeneratedMessageV3 implements IPMatcher.IPRangeMatcherOrBuilder
 Specifies a list of IP address ranges and a match action.
 
Protobuf type xds.type.matcher.v3.IPMatcher.IPRangeMatcher
See Also:
  • Field Details

  • Method Details

    • newInstance

      protected Object newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
      Overrides:
      newInstance in class com.google.protobuf.GeneratedMessageV3
    • 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
    • getRangesList

      public List<CidrRange> getRangesList()
       A non-empty set of CIDR ranges.
       
      repeated .xds.core.v3.CidrRange ranges = 1 [(.validate.rules) = { ... }
      Specified by:
      getRangesList in interface IPMatcher.IPRangeMatcherOrBuilder
    • getRangesOrBuilderList

      public List<? extends CidrRangeOrBuilder> getRangesOrBuilderList()
       A non-empty set of CIDR ranges.
       
      repeated .xds.core.v3.CidrRange ranges = 1 [(.validate.rules) = { ... }
      Specified by:
      getRangesOrBuilderList in interface IPMatcher.IPRangeMatcherOrBuilder
    • getRangesCount

      public int getRangesCount()
       A non-empty set of CIDR ranges.
       
      repeated .xds.core.v3.CidrRange ranges = 1 [(.validate.rules) = { ... }
      Specified by:
      getRangesCount in interface IPMatcher.IPRangeMatcherOrBuilder
    • getRanges

      public CidrRange getRanges(int index)
       A non-empty set of CIDR ranges.
       
      repeated .xds.core.v3.CidrRange ranges = 1 [(.validate.rules) = { ... }
      Specified by:
      getRanges in interface IPMatcher.IPRangeMatcherOrBuilder
    • getRangesOrBuilder

      public CidrRangeOrBuilder getRangesOrBuilder(int index)
       A non-empty set of CIDR ranges.
       
      repeated .xds.core.v3.CidrRange ranges = 1 [(.validate.rules) = { ... }
      Specified by:
      getRangesOrBuilder in interface IPMatcher.IPRangeMatcherOrBuilder
    • hasOnMatch

      public boolean hasOnMatch()
       Match action to apply when the IP address is within one of the CIDR ranges.
       
      .xds.type.matcher.v3.Matcher.OnMatch on_match = 2;
      Specified by:
      hasOnMatch in interface IPMatcher.IPRangeMatcherOrBuilder
      Returns:
      Whether the onMatch field is set.
    • getOnMatch

      public Matcher.OnMatch getOnMatch()
       Match action to apply when the IP address is within one of the CIDR ranges.
       
      .xds.type.matcher.v3.Matcher.OnMatch on_match = 2;
      Specified by:
      getOnMatch in interface IPMatcher.IPRangeMatcherOrBuilder
      Returns:
      The onMatch.
    • getOnMatchOrBuilder

      public Matcher.OnMatchOrBuilder getOnMatchOrBuilder()
       Match action to apply when the IP address is within one of the CIDR ranges.
       
      .xds.type.matcher.v3.Matcher.OnMatch on_match = 2;
      Specified by:
      getOnMatchOrBuilder in interface IPMatcher.IPRangeMatcherOrBuilder
    • getExclusive

      public boolean getExclusive()
       Indicates whether this match option should be considered if there is a
       more specific matcher. Exclusive matchers are not selected whenever a
       more specific matcher exists (e.g. matcher with a longer prefix) even
       when the more specific matcher fails its nested match condition.
       Non-exclusive matchers are considered if the more specific matcher
       exists but its nested match condition does not entirely match.
       Non-exclusive matchers are selected in the order of their specificity
       first (longest prefix first), then the order of declaration next.
      
       For example, consider two range matchers: an exclusive matcher *X* on
       ``0.0.0.0/0`` and a matcher *Y* on ``192.0.0.0/2`` with a nested match
       condition *Z*. For the input IP ``192.168.0.1`` matcher *Y* is the most
       specific. If its nested match condition *Z* does not accept the input,
       then the less specific matcher *X* does not apply either despite the
       input being within the range, because matcher *X* is exclusive.
      
       The opposite is true if matcher *X* is not marked as exclusive. In that
       case matcher *X* always matches whenever matcher "*Y* rejects the input.
       
      bool exclusive = 3;
      Specified by:
      getExclusive in interface IPMatcher.IPRangeMatcherOrBuilder
      Returns:
      The exclusive.
    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessageV3
    • writeTo

      public void writeTo(com.google.protobuf.CodedOutputStream output) throws IOException
      Specified by:
      writeTo in interface com.google.protobuf.MessageLite
      Overrides:
      writeTo in class com.google.protobuf.GeneratedMessageV3
      Throws:
      IOException
    • getSerializedSize

      public int getSerializedSize()
      Specified by:
      getSerializedSize in interface com.google.protobuf.MessageLite
      Overrides:
      getSerializedSize in class com.google.protobuf.GeneratedMessageV3
    • equals

      public boolean equals(Object obj)
      Specified by:
      equals in interface com.google.protobuf.Message
      Overrides:
      equals in class com.google.protobuf.AbstractMessage
    • hashCode

      public int hashCode()
      Specified by:
      hashCode in interface com.google.protobuf.Message
      Overrides:
      hashCode in class com.google.protobuf.AbstractMessage
    • parseFrom

      public static IPMatcher.IPRangeMatcher parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static IPMatcher.IPRangeMatcher parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static IPMatcher.IPRangeMatcher parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static IPMatcher.IPRangeMatcher parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static IPMatcher.IPRangeMatcher parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static IPMatcher.IPRangeMatcher parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static IPMatcher.IPRangeMatcher parseFrom(InputStream input) throws IOException
      Throws:
      IOException
    • parseFrom

      public static IPMatcher.IPRangeMatcher parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Throws:
      IOException
    • parseDelimitedFrom

      public static IPMatcher.IPRangeMatcher parseDelimitedFrom(InputStream input) throws IOException
      Throws:
      IOException
    • parseDelimitedFrom

      public static IPMatcher.IPRangeMatcher parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Throws:
      IOException
    • parseFrom

      public static IPMatcher.IPRangeMatcher parseFrom(com.google.protobuf.CodedInputStream input) throws IOException
      Throws:
      IOException
    • parseFrom

      public static IPMatcher.IPRangeMatcher parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Throws:
      IOException
    • newBuilderForType

      public IPMatcher.IPRangeMatcher.Builder newBuilderForType()
      Specified by:
      newBuilderForType in interface com.google.protobuf.Message
      Specified by:
      newBuilderForType in interface com.google.protobuf.MessageLite
    • newBuilder

      public static IPMatcher.IPRangeMatcher.Builder newBuilder()
    • newBuilder

      public static IPMatcher.IPRangeMatcher.Builder newBuilder(IPMatcher.IPRangeMatcher prototype)
    • toBuilder

      Specified by:
      toBuilder in interface com.google.protobuf.Message
      Specified by:
      toBuilder in interface com.google.protobuf.MessageLite
    • newBuilderForType

      protected IPMatcher.IPRangeMatcher.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
      Specified by:
      newBuilderForType in class com.google.protobuf.GeneratedMessageV3
    • getDefaultInstance

      public static IPMatcher.IPRangeMatcher getDefaultInstance()
    • parser

      public static com.google.protobuf.Parser<IPMatcher.IPRangeMatcher> parser()
    • getParserForType

      public com.google.protobuf.Parser<IPMatcher.IPRangeMatcher> getParserForType()
      Specified by:
      getParserForType in interface com.google.protobuf.Message
      Specified by:
      getParserForType in interface com.google.protobuf.MessageLite
      Overrides:
      getParserForType in class com.google.protobuf.GeneratedMessageV3
    • getDefaultInstanceForType

      public IPMatcher.IPRangeMatcher getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder