com.sssw.srv.busobj
Class AgoHttpRequestEvent
java.lang.Object
|
+--java.util.EventObject
|
+--com.sssw.srv.busobj.AgoBusinessObjectEvent
|
+--com.sssw.srv.busobj.AgoHttpRequestEvent
- All Implemented Interfaces:
- AgiHttpServletRequest, HttpServletRequest, Serializable, ServletRequest
- public class AgoHttpRequestEvent
- extends AgoBusinessObjectEvent
- implements AgiHttpServletRequest
Extends javax.servlet.ServletRequest for use with
<INPUT TYPE=FILE>
fields in a multipart/form-data POST.
- See Also:
- Serialized Form
Methods implemented from interface javax.servlet.http.HttpServletRequest |
getAuthType,
getCookies,
getDateHeader,
getHeader,
getHeaderNames,
getIntHeader,
getMethod,
getPathInfo,
getPathTranslated,
getQueryString,
getRemoteUser,
getRequestedSessionId,
getRequestURI,
getServletPath,
getSession,
isRequestedSessionIdFromCookie,
isRequestedSessionIdFromUrl,
isRequestedSessionIdFromURL,
isRequestedSessionIdValid |
Methods implemented from interface javax.servlet.ServletRequest |
getAttribute,
getAttributeNames,
getCharacterEncoding,
getContentLength,
getContentType,
getInputStream,
getParameter,
getParameterNames,
getParameterValues,
getProtocol,
getReader,
getRealPath,
getRemoteAddr,
getRemoteHost,
getScheme,
getServerName,
getServerPort,
setAttribute |
AgoHttpRequestEvent
public AgoHttpRequestEvent()
getFileContent
public byte[] getFileContent(String name)
- Returns the file content from an HTML form-field of type
<INPUT TYPE=FILE>
- Specified by:
- getFileContent in interface AgiHttpServletRequest
- Parameters:
name
- a String- Usage:
The file pathname is accessed using getValue()
for the same Parameter name.
- See Also:
AgoHttpRequestEvent.getFileContentType( String name )
getFileContentType
public String getFileContentType(String name)
- Returns the file content type (MimeType) from an HTML form-field of type
<INPUT TYPE=FILE>
.
- Specified by:
- getFileContentType in interface AgiHttpServletRequest
- Parameters:
name
- parameter name as a String- Usage:
The file pathname is accessed using getValue for the same Parameter name.
- See Also:
AgoHttpRequestEvent.getFileContent( String name )
getExtensionFromURL
public static String getExtensionFromURL(String url)
throws AgoUnrecoverableSystemException
- Utility routine to get the extension from a String
form of an URL.
- Parameters:
url
- an URL in String form.- Usage:
Note that in 1.0 this method used to throw AgentException.
It now throws AgoUnrecoverableSystemException on error.
The upgrade tool that upgrades UserContentAgents to Servlets
(and TableListeners) makes this conversion on preexisting code.
getContentTypeFromExtension
public static String getContentTypeFromExtension(String ext)
throws AgoUnrecoverableSystemException
- Utility routine to get the content type in string
form from an extension in String form.
- Parameters:
ext
- an extension in String form.
decodeURLEncodedForm
public static Hashtable decodeURLEncodedForm(String s)
- Takes a string encoded as an application/x-www-form-urlencoded
MIME type and parses it into a Hashtable of query terms.
- Returns:
- A Hashtable of the query terms or null on error
getDatabaseURL
public URL getDatabaseURL()
- Return the current database's URL.
- Specified by:
- getDatabaseURL in interface AgiHttpServletRequest
- Overrides:
- getDatabaseURL in class AgoBusinessObjectEvent
- Usage:
- Used for HTTP 1.1 requests
to ensure that the hostname is provided by the servlet's request
header.