Package com.mendix.m2ee.api
Interface IMxRuntimeRequest
-
public interface IMxRuntimeRequestThis interface represents a request coming in to the runtime.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description byte[]createFingerprint()This method is only here for backwards compatibility and should not be used.IAppContainergetContext()Returns the AppContainer corresponding to this request.java.lang.StringgetCookie(java.lang.String cookieName)Returns the value of the cookie.java.lang.StringgetCookie(java.lang.String cookieName, boolean isHostOnly)java.lang.StringgetFileItemName()Returns the name of the file.java.io.InputStreamgetFileItemStream()Returns the file as a binary data stream.java.lang.StringgetHeader(java.lang.String header)Returns the value of a header.javax.servlet.http.HttpServletRequestgetHttpServletRequest()Returns the HttpServletRequest underlying this runtime request.java.io.InputStreamgetInputStream()Returns the body of the request as a binary data stream.java.lang.StringgetParameter(java.lang.String paramName)Returns the parameter value.java.lang.StringgetRemoteAddr()Returns the IP address of the client that sent the request.java.lang.StringgetRequestString()Returns the request serialized as a string.java.lang.StringgetResourcePath()Returns the extra path information of this request, for example when the full URL is http://www.example.com/web/ui/index.htm, it returns /web/ui/index.htmlbooleanisFileUpload()Returns true if this request is a file upload.
-
-
-
Method Detail
-
getRequestString
java.lang.String getRequestString()
Returns the request serialized as a string.
-
getParameter
java.lang.String getParameter(java.lang.String paramName)
Returns the parameter value.- Parameters:
paramName- the parameter name- Returns:
- the value of the parameter if it exists, otherwise null
-
getCookie
java.lang.String getCookie(java.lang.String cookieName)
Returns the value of the cookie.- Parameters:
cookieName- the name of the cookie- Returns:
- the value of the cookie if it exists, otherwise null
-
getCookie
java.lang.String getCookie(java.lang.String cookieName, boolean isHostOnly)
-
isFileUpload
boolean isFileUpload()
Returns true if this request is a file upload.
-
getRemoteAddr
java.lang.String getRemoteAddr()
Returns the IP address of the client that sent the request.
-
getInputStream
java.io.InputStream getInputStream() throws java.io.IOExceptionReturns the body of the request as a binary data stream.- Returns:
- the body of the request
- Throws:
java.io.IOException- if an input or output exception occurs
-
getFileItemStream
java.io.InputStream getFileItemStream() throws java.io.IOExceptionReturns the file as a binary data stream.- Returns:
- the binary data stream
- Throws:
java.lang.RuntimeException- if the request is not a file uploadjava.io.IOException
-
getFileItemName
java.lang.String getFileItemName()
Returns the name of the file.- Returns:
- the name of the file
- Throws:
java.lang.RuntimeException- if the request is not a file upload
-
getResourcePath
java.lang.String getResourcePath()
Returns the extra path information of this request, for example when the full URL is http://www.example.com/web/ui/index.htm, it returns /web/ui/index.html
-
getHeader
java.lang.String getHeader(java.lang.String header)
Returns the value of a header.- Parameters:
header- the header name- Returns:
- the value of the header
-
getContext
IAppContainer getContext()
Returns the AppContainer corresponding to this request.
-
getHttpServletRequest
javax.servlet.http.HttpServletRequest getHttpServletRequest()
Returns the HttpServletRequest underlying this runtime request.
-
createFingerprint
byte[] createFingerprint()
This method is only here for backwards compatibility and should not be used.
-
-