Java javax.servlet ServletRequest fields, constructors, methods, implement or subclass

Example usage for Java javax.servlet ServletRequest fields, constructors, methods, implement or subclass

Introduction

In this page you can find the methods, fields and constructors for javax.servlet ServletRequest.

The text is from its open source code.

Implementation

javax.servlet.ServletRequest has the following implementations.
Click this link to see all its implementation.

Method

AsyncContextgetAsyncContext()
Gets the AsyncContext that was created or reinitialized by the most recent invocation of #startAsync or #startAsync(ServletRequest,ServletResponse) on this request.
ObjectgetAttribute(String name)
Returns the value of the named attribute as an Object, or null if no attribute of the given name exists.
EnumerationgetAttributeNames()
Returns an Enumeration containing the names of the attributes available to this request.
StringgetCharacterEncoding()
Returns the name of the character encoding used in the body of this request.
ClassgetClass()
Returns the runtime class of this Object .
intgetContentLength()
Returns the length, in bytes, of the request body and made available by the input stream, or -1 if the length is not known ir is greater than Integer.MAX_VALUE.
StringgetContentType()
Returns the MIME type of the body of the request, or null if the type is not known.
DispatcherTypegetDispatcherType()
Gets the dispatcher type of this request.
ServletInputStreamgetInputStream()
Retrieves the body of the request as binary data using a ServletInputStream .
StringgetLocalAddr()
Returns the Internet Protocol (IP) address of the interface on which the request was received.
LocalegetLocale()
Returns the preferred Locale that the client will accept content in, based on the Accept-Language header.
EnumerationgetLocales()
Returns an Enumeration of Locale objects indicating, in decreasing order starting with the preferred locale, the locales that are acceptable to the client based on the Accept-Language header.
StringgetLocalName()
Returns the host name of the Internet Protocol (IP) interface on which the request was received.
intgetLocalPort()
Returns the Internet Protocol (IP) port number of the interface on which the request was received.
StringgetParameter(String name)
Returns the value of a request parameter as a String, or null if the parameter does not exist.
MapgetParameterMap()
Returns a java.util.Map of the parameters of this request.
EnumerationgetParameterNames()
Returns an Enumeration of String objects containing the names of the parameters contained in this request.
String[]getParameterValues(String name)
Returns an array of String objects containing all of the values the given request parameter has, or null if the parameter does not exist.
StringgetProtocol()
Returns the name and version of the protocol the request uses in the form protocol/majorVersion.minorVersion, for example, HTTP/1.1.
BufferedReadergetReader()
Retrieves the body of the request as character data using a BufferedReader.
StringgetRemoteAddr()
Returns the Internet Protocol (IP) address of the client or last proxy that sent the request.
StringgetRemoteHost()
Returns the fully qualified name of the client or the last proxy that sent the request.
intgetRemotePort()
Returns the Internet Protocol (IP) source port of the client or last proxy that sent the request.
RequestDispatchergetRequestDispatcher(String path)
Returns a RequestDispatcher object that acts as a wrapper for the resource located at the given path.
StringgetScheme()
Returns the name of the scheme used to make this request, for example, http, https, or ftp.
StringgetServerName()
Returns the host name of the server to which the request was sent.
intgetServerPort()
Returns the port number to which the request was sent.
ServletContextgetServletContext()
Gets the servlet context to which this ServletRequest was last dispatched.
booleanisAsyncStarted()
Checks if this request has been put into asynchronous mode.
booleanisSecure()
Returns a boolean indicating whether this request was made using a secure channel, such as HTTPS.
voidremoveAttribute(String name)
Removes an attribute from this request.
voidsetAttribute(String name, Object o)
Stores an attribute in this request.
voidsetCharacterEncoding(String env)
Overrides the name of the character encoding used in the body of this request.
AsyncContextstartAsync()
Puts this request into asynchronous mode, and initializes its AsyncContext with the original (unwrapped) ServletRequest and ServletResponse objects.
StringtoString()
Returns a string representation of the object.