Class HttpRoute.RouteRule.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<HttpRoute.RouteRule.Builder>
com.google.cloud.networkservices.v1.HttpRoute.RouteRule.Builder
All Implemented Interfaces:
HttpRoute.RouteRuleOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
Enclosing class:
HttpRoute.RouteRule

public static final class HttpRoute.RouteRule.Builder extends com.google.protobuf.GeneratedMessage.Builder<HttpRoute.RouteRule.Builder> implements HttpRoute.RouteRuleOrBuilder
 Specifies how to match traffic and how to route traffic when traffic is
 matched.
 
Protobuf type google.cloud.networkservices.v1.HttpRoute.RouteRule
  • Method Details

    • getDescriptor

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

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessage.Builder<HttpRoute.RouteRule.Builder>
    • clear

      Specified by:
      clear in interface com.google.protobuf.Message.Builder
      Specified by:
      clear in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clear in class com.google.protobuf.GeneratedMessage.Builder<HttpRoute.RouteRule.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.GeneratedMessage.Builder<HttpRoute.RouteRule.Builder>
    • getDefaultInstanceForType

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

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

      public HttpRoute.RouteRule buildPartial()
      Specified by:
      buildPartial in interface com.google.protobuf.Message.Builder
      Specified by:
      buildPartial in interface com.google.protobuf.MessageLite.Builder
    • mergeFrom

      public HttpRoute.RouteRule.Builder mergeFrom(com.google.protobuf.Message other)
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<HttpRoute.RouteRule.Builder>
    • mergeFrom

    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessage.Builder<HttpRoute.RouteRule.Builder>
    • mergeFrom

      public HttpRoute.RouteRule.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Specified by:
      mergeFrom in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<HttpRoute.RouteRule.Builder>
      Throws:
      IOException
    • getMatchesList

      public List<HttpRoute.RouteMatch> getMatchesList()
       A list of matches define conditions used for matching the rule against
       incoming HTTP requests. Each match is independent, i.e. this rule will be
       matched if ANY one of the matches is satisfied.
      
       If no matches field is specified, this rule will unconditionally match
       traffic.
      
       If a default rule is desired to be configured, add a rule with no matches
       specified to the end of the rules list.
       
      repeated .google.cloud.networkservices.v1.HttpRoute.RouteMatch matches = 1;
      Specified by:
      getMatchesList in interface HttpRoute.RouteRuleOrBuilder
    • getMatchesCount

      public int getMatchesCount()
       A list of matches define conditions used for matching the rule against
       incoming HTTP requests. Each match is independent, i.e. this rule will be
       matched if ANY one of the matches is satisfied.
      
       If no matches field is specified, this rule will unconditionally match
       traffic.
      
       If a default rule is desired to be configured, add a rule with no matches
       specified to the end of the rules list.
       
      repeated .google.cloud.networkservices.v1.HttpRoute.RouteMatch matches = 1;
      Specified by:
      getMatchesCount in interface HttpRoute.RouteRuleOrBuilder
    • getMatches

      public HttpRoute.RouteMatch getMatches(int index)
       A list of matches define conditions used for matching the rule against
       incoming HTTP requests. Each match is independent, i.e. this rule will be
       matched if ANY one of the matches is satisfied.
      
       If no matches field is specified, this rule will unconditionally match
       traffic.
      
       If a default rule is desired to be configured, add a rule with no matches
       specified to the end of the rules list.
       
      repeated .google.cloud.networkservices.v1.HttpRoute.RouteMatch matches = 1;
      Specified by:
      getMatches in interface HttpRoute.RouteRuleOrBuilder
    • setMatches

      public HttpRoute.RouteRule.Builder setMatches(int index, HttpRoute.RouteMatch value)
       A list of matches define conditions used for matching the rule against
       incoming HTTP requests. Each match is independent, i.e. this rule will be
       matched if ANY one of the matches is satisfied.
      
       If no matches field is specified, this rule will unconditionally match
       traffic.
      
       If a default rule is desired to be configured, add a rule with no matches
       specified to the end of the rules list.
       
      repeated .google.cloud.networkservices.v1.HttpRoute.RouteMatch matches = 1;
    • setMatches

      public HttpRoute.RouteRule.Builder setMatches(int index, HttpRoute.RouteMatch.Builder builderForValue)
       A list of matches define conditions used for matching the rule against
       incoming HTTP requests. Each match is independent, i.e. this rule will be
       matched if ANY one of the matches is satisfied.
      
       If no matches field is specified, this rule will unconditionally match
       traffic.
      
       If a default rule is desired to be configured, add a rule with no matches
       specified to the end of the rules list.
       
      repeated .google.cloud.networkservices.v1.HttpRoute.RouteMatch matches = 1;
    • addMatches

       A list of matches define conditions used for matching the rule against
       incoming HTTP requests. Each match is independent, i.e. this rule will be
       matched if ANY one of the matches is satisfied.
      
       If no matches field is specified, this rule will unconditionally match
       traffic.
      
       If a default rule is desired to be configured, add a rule with no matches
       specified to the end of the rules list.
       
      repeated .google.cloud.networkservices.v1.HttpRoute.RouteMatch matches = 1;
    • addMatches

      public HttpRoute.RouteRule.Builder addMatches(int index, HttpRoute.RouteMatch value)
       A list of matches define conditions used for matching the rule against
       incoming HTTP requests. Each match is independent, i.e. this rule will be
       matched if ANY one of the matches is satisfied.
      
       If no matches field is specified, this rule will unconditionally match
       traffic.
      
       If a default rule is desired to be configured, add a rule with no matches
       specified to the end of the rules list.
       
      repeated .google.cloud.networkservices.v1.HttpRoute.RouteMatch matches = 1;
    • addMatches

      public HttpRoute.RouteRule.Builder addMatches(HttpRoute.RouteMatch.Builder builderForValue)
       A list of matches define conditions used for matching the rule against
       incoming HTTP requests. Each match is independent, i.e. this rule will be
       matched if ANY one of the matches is satisfied.
      
       If no matches field is specified, this rule will unconditionally match
       traffic.
      
       If a default rule is desired to be configured, add a rule with no matches
       specified to the end of the rules list.
       
      repeated .google.cloud.networkservices.v1.HttpRoute.RouteMatch matches = 1;
    • addMatches

      public HttpRoute.RouteRule.Builder addMatches(int index, HttpRoute.RouteMatch.Builder builderForValue)
       A list of matches define conditions used for matching the rule against
       incoming HTTP requests. Each match is independent, i.e. this rule will be
       matched if ANY one of the matches is satisfied.
      
       If no matches field is specified, this rule will unconditionally match
       traffic.
      
       If a default rule is desired to be configured, add a rule with no matches
       specified to the end of the rules list.
       
      repeated .google.cloud.networkservices.v1.HttpRoute.RouteMatch matches = 1;
    • addAllMatches

      public HttpRoute.RouteRule.Builder addAllMatches(Iterable<? extends HttpRoute.RouteMatch> values)
       A list of matches define conditions used for matching the rule against
       incoming HTTP requests. Each match is independent, i.e. this rule will be
       matched if ANY one of the matches is satisfied.
      
       If no matches field is specified, this rule will unconditionally match
       traffic.
      
       If a default rule is desired to be configured, add a rule with no matches
       specified to the end of the rules list.
       
      repeated .google.cloud.networkservices.v1.HttpRoute.RouteMatch matches = 1;
    • clearMatches

      public HttpRoute.RouteRule.Builder clearMatches()
       A list of matches define conditions used for matching the rule against
       incoming HTTP requests. Each match is independent, i.e. this rule will be
       matched if ANY one of the matches is satisfied.
      
       If no matches field is specified, this rule will unconditionally match
       traffic.
      
       If a default rule is desired to be configured, add a rule with no matches
       specified to the end of the rules list.
       
      repeated .google.cloud.networkservices.v1.HttpRoute.RouteMatch matches = 1;
    • removeMatches

      public HttpRoute.RouteRule.Builder removeMatches(int index)
       A list of matches define conditions used for matching the rule against
       incoming HTTP requests. Each match is independent, i.e. this rule will be
       matched if ANY one of the matches is satisfied.
      
       If no matches field is specified, this rule will unconditionally match
       traffic.
      
       If a default rule is desired to be configured, add a rule with no matches
       specified to the end of the rules list.
       
      repeated .google.cloud.networkservices.v1.HttpRoute.RouteMatch matches = 1;
    • getMatchesBuilder

      public HttpRoute.RouteMatch.Builder getMatchesBuilder(int index)
       A list of matches define conditions used for matching the rule against
       incoming HTTP requests. Each match is independent, i.e. this rule will be
       matched if ANY one of the matches is satisfied.
      
       If no matches field is specified, this rule will unconditionally match
       traffic.
      
       If a default rule is desired to be configured, add a rule with no matches
       specified to the end of the rules list.
       
      repeated .google.cloud.networkservices.v1.HttpRoute.RouteMatch matches = 1;
    • getMatchesOrBuilder

      public HttpRoute.RouteMatchOrBuilder getMatchesOrBuilder(int index)
       A list of matches define conditions used for matching the rule against
       incoming HTTP requests. Each match is independent, i.e. this rule will be
       matched if ANY one of the matches is satisfied.
      
       If no matches field is specified, this rule will unconditionally match
       traffic.
      
       If a default rule is desired to be configured, add a rule with no matches
       specified to the end of the rules list.
       
      repeated .google.cloud.networkservices.v1.HttpRoute.RouteMatch matches = 1;
      Specified by:
      getMatchesOrBuilder in interface HttpRoute.RouteRuleOrBuilder
    • getMatchesOrBuilderList

      public List<? extends HttpRoute.RouteMatchOrBuilder> getMatchesOrBuilderList()
       A list of matches define conditions used for matching the rule against
       incoming HTTP requests. Each match is independent, i.e. this rule will be
       matched if ANY one of the matches is satisfied.
      
       If no matches field is specified, this rule will unconditionally match
       traffic.
      
       If a default rule is desired to be configured, add a rule with no matches
       specified to the end of the rules list.
       
      repeated .google.cloud.networkservices.v1.HttpRoute.RouteMatch matches = 1;
      Specified by:
      getMatchesOrBuilderList in interface HttpRoute.RouteRuleOrBuilder
    • addMatchesBuilder

      public HttpRoute.RouteMatch.Builder addMatchesBuilder()
       A list of matches define conditions used for matching the rule against
       incoming HTTP requests. Each match is independent, i.e. this rule will be
       matched if ANY one of the matches is satisfied.
      
       If no matches field is specified, this rule will unconditionally match
       traffic.
      
       If a default rule is desired to be configured, add a rule with no matches
       specified to the end of the rules list.
       
      repeated .google.cloud.networkservices.v1.HttpRoute.RouteMatch matches = 1;
    • addMatchesBuilder

      public HttpRoute.RouteMatch.Builder addMatchesBuilder(int index)
       A list of matches define conditions used for matching the rule against
       incoming HTTP requests. Each match is independent, i.e. this rule will be
       matched if ANY one of the matches is satisfied.
      
       If no matches field is specified, this rule will unconditionally match
       traffic.
      
       If a default rule is desired to be configured, add a rule with no matches
       specified to the end of the rules list.
       
      repeated .google.cloud.networkservices.v1.HttpRoute.RouteMatch matches = 1;
    • getMatchesBuilderList

      public List<HttpRoute.RouteMatch.Builder> getMatchesBuilderList()
       A list of matches define conditions used for matching the rule against
       incoming HTTP requests. Each match is independent, i.e. this rule will be
       matched if ANY one of the matches is satisfied.
      
       If no matches field is specified, this rule will unconditionally match
       traffic.
      
       If a default rule is desired to be configured, add a rule with no matches
       specified to the end of the rules list.
       
      repeated .google.cloud.networkservices.v1.HttpRoute.RouteMatch matches = 1;
    • hasAction

      public boolean hasAction()
       The detailed rule defining how to route matched traffic.
       
      .google.cloud.networkservices.v1.HttpRoute.RouteAction action = 2;
      Specified by:
      hasAction in interface HttpRoute.RouteRuleOrBuilder
      Returns:
      Whether the action field is set.
    • getAction

      public HttpRoute.RouteAction getAction()
       The detailed rule defining how to route matched traffic.
       
      .google.cloud.networkservices.v1.HttpRoute.RouteAction action = 2;
      Specified by:
      getAction in interface HttpRoute.RouteRuleOrBuilder
      Returns:
      The action.
    • setAction

       The detailed rule defining how to route matched traffic.
       
      .google.cloud.networkservices.v1.HttpRoute.RouteAction action = 2;
    • setAction

      public HttpRoute.RouteRule.Builder setAction(HttpRoute.RouteAction.Builder builderForValue)
       The detailed rule defining how to route matched traffic.
       
      .google.cloud.networkservices.v1.HttpRoute.RouteAction action = 2;
    • mergeAction

       The detailed rule defining how to route matched traffic.
       
      .google.cloud.networkservices.v1.HttpRoute.RouteAction action = 2;
    • clearAction

      public HttpRoute.RouteRule.Builder clearAction()
       The detailed rule defining how to route matched traffic.
       
      .google.cloud.networkservices.v1.HttpRoute.RouteAction action = 2;
    • getActionBuilder

      public HttpRoute.RouteAction.Builder getActionBuilder()
       The detailed rule defining how to route matched traffic.
       
      .google.cloud.networkservices.v1.HttpRoute.RouteAction action = 2;
    • getActionOrBuilder

      public HttpRoute.RouteActionOrBuilder getActionOrBuilder()
       The detailed rule defining how to route matched traffic.
       
      .google.cloud.networkservices.v1.HttpRoute.RouteAction action = 2;
      Specified by:
      getActionOrBuilder in interface HttpRoute.RouteRuleOrBuilder