Class ResteasyHttpHeaders

    • Method Detail

      • getRequestHeaders

        public MultivaluedMap<String,​String> getRequestHeaders()
        Description copied from interface: HttpHeaders
        Get the values of HTTP request headers. The returned Map is case-insensitive wrt. keys and is read-only. The method never returns null.
        Specified by:
        getRequestHeaders in interface HttpHeaders
        Returns:
        a read-only map of header names and values.
      • testParsing

        public void testParsing()
      • getRequestHeader

        public List<String> getRequestHeader​(String name)
        Description copied from interface: HttpHeaders
        Get the values of a HTTP request header if the header exists on the current request. The returned value will be a read-only List if the specified header exists or null if it does not. This is a shortcut for getRequestHeaders().get(name).
        Specified by:
        getRequestHeader in interface HttpHeaders
        Parameters:
        name - the header name, case insensitive.
        Returns:
        a read-only list of header values if the specified header exists, otherwise null.
      • getCookies

        public Map<String,​Cookie> getCookies()
        Description copied from interface: HttpHeaders
        Get any cookies that accompanied the request.
        Specified by:
        getCookies in interface HttpHeaders
        Returns:
        a read-only map of cookie name (String) to Cookie.
      • getDate

        public Date getDate()
        Description copied from interface: HttpHeaders
        Get message date.
        Specified by:
        getDate in interface HttpHeaders
        Returns:
        the message date, otherwise null if not present.
      • getLanguage

        public Locale getLanguage()
        Description copied from interface: HttpHeaders
        Get the language of the request entity.
        Specified by:
        getLanguage in interface HttpHeaders
        Returns:
        the language of the entity or null if not specified.
      • getLength

        public int getLength()
        Description copied from interface: HttpHeaders
        Get Content-Length value.
        Specified by:
        getLength in interface HttpHeaders
        Returns:
        Content-Length as integer if present and valid number. In other cases returns -1.
      • getMediaType

        public MediaType getMediaType()
        Description copied from interface: HttpHeaders
        Get the media type of the request entity.
        Specified by:
        getMediaType in interface HttpHeaders
        Returns:
        the media type or null if there is no request entity.
      • getAcceptableMediaTypes

        public List<MediaType> getAcceptableMediaTypes()
        Description copied from interface: HttpHeaders

        Get a list of media types that are acceptable for the response.

        If no acceptable media types are specified, a read-only list containing a single wildcard media type instance is returned.
        Specified by:
        getAcceptableMediaTypes in interface HttpHeaders
        Returns:
        a read-only list of requested response media types sorted according to their q-value, with highest preference first.
      • getAcceptableLanguages

        public List<Locale> getAcceptableLanguages()
        Description copied from interface: HttpHeaders

        Get a list of languages that are acceptable for the response.

        If no acceptable languages are specified, a read-only list containing a single wildcard Locale instance (with language field set to "*") is returned.
        Specified by:
        getAcceptableLanguages in interface HttpHeaders
        Returns:
        a read-only list of acceptable languages sorted according to their q-value, with highest preference first.