Class RequestParamsBuilder


  • @BetaApi
    public class RequestParamsBuilder
    extends java.lang.Object
    This builder class builds a request params map that will be used by autogenerated implementation of RequestParamsExtractor.
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void add​(java.lang.String fieldValue, java.lang.String headerKey, com.google.api.pathtemplate.PathTemplate pathTemplate)
      Add an entry to paramsBuilder by match-and-extract field values from requests based on pre-configured path templates.
      java.util.Map<java.lang.String,​java.lang.String> build()  
      static RequestParamsBuilder create()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • add

        public void add​(java.lang.String fieldValue,
                        java.lang.String headerKey,
                        com.google.api.pathtemplate.PathTemplate pathTemplate)
        Add an entry to paramsBuilder by match-and-extract field values from requests based on pre-configured path templates. This method is called repeatedly for each configured routing rule parameter, it's possible that the incoming field value from request is null or there is no matches found, we'll continue the match-and-extract process for the next routing rule parameter in such case.
        Parameters:
        fieldValue - the field value from a request
        headerKey - the header key for the routing header param
        pathTemplate - PathTemplate the path template used for match-and-extract
      • build

        public java.util.Map<java.lang.String,​java.lang.String> build()