Class ParameterSupport

java.lang.Object
org.apache.sling.engine.impl.parameters.ParameterSupport

public class ParameterSupport extends Object
  • Field Details

    • PARAMETER_FORMENCODING

      public static final String PARAMETER_FORMENCODING
      The name of the form encoding request parameter indicating the character encoding of submitted request parameters. This request parameter overwrites any value of the ServletRequest.getCharacterEncoding() method (which unfortunately happens to be returning null most of the time.
      See Also:
    • MARKER_IS_SERVICE_PROCESSING

      public static final String MARKER_IS_SERVICE_PROCESSING
      Request attribute which is set if the current request is "started" by calling SlingRequestProcessor.processRequest(HttpServletRequest, HttpServletResponse, ResourceResolver) This marker is evaluated in getRequestParameterMapInternal().
    • SLING_UPLOADMODE_HEADER

      public static final String SLING_UPLOADMODE_HEADER
      name of the header used to identify an upload mode
      See Also:
    • UPLOADMODE_PARAM

      public static final String UPLOADMODE_PARAM
      name of the parameter used to identify upload mode
      See Also:
    • REQUEST_PARTS_ITERATOR_ATTRIBUTE

      public static final String REQUEST_PARTS_ITERATOR_ATTRIBUTE
      request attribute that stores the parts iterator when streaming
      See Also:
    • STREAM_UPLOAD

      public static final String STREAM_UPLOAD
      value of upload mode header/parameter indicating streaming is requested
      See Also:
  • Method Details

    • getInstance

      public static ParameterSupport getInstance(javax.servlet.http.HttpServletRequest request)
      Returns the ParameterSupport instance supporting request parameter for the give request. For a single request only a single instance is actually used. This single instance is cached as a request attribute. If such an attribute already exists which is not an instance of this class, the request parameter is replaced.
      Parameters:
      request - The HttpServletRequest for which to return request parameter support.
      Returns:
      The ParameterSupport for the given request.
    • getParameterSupportRequestWrapper

      public static javax.servlet.http.HttpServletRequestWrapper getParameterSupportRequestWrapper(javax.servlet.http.HttpServletRequest request)
      Returns a HttpServletRequestWrapper which implements request parameter access backed by an instance of the ParameterSupport class.

      Parameters:
      request - The HttpServletRequest to wrap
      Returns:
      The wrapped request
    • requestDataUsed

      public boolean requestDataUsed()
    • getParameter

      public String getParameter(String name)
    • getParameterValues

      public String[] getParameterValues(String name)
    • getParameterMap

      public Map<String,String[]> getParameterMap()
    • getParameterNames

      public Enumeration<String> getParameterNames()
    • getRequestParameter

      public RequestParameter getRequestParameter(String name)
    • getRequestParameters

      public RequestParameter[] getRequestParameters(String name)
    • getPart

      public Object getPart(String name)
    • getParts

      public Collection<?> getParts()
    • getRequestParameterMap

      public RequestParameterMap getRequestParameterMap()
    • getRequestParameterList

      public List<RequestParameter> getRequestParameterList()