er.extensions.appserver
Class ERXPathDirectActionRequestHandler
java.lang.Object
com.webobjects.appserver.WORequestHandler
com.webobjects.appserver._private.WOActionRequestHandler
com.webobjects.appserver._private.WODirectActionRequestHandler
er.extensions.appserver.ERXDirectActionRequestHandler
er.extensions.appserver.ERXPathDirectActionRequestHandler
public class ERXPathDirectActionRequestHandler
- extends ERXDirectActionRequestHandler
The path direct action request handler allows for storing information
in the request path. For instance you could have the request path:
/WebObjects/MyApp.woa/wpa/com.foo.SomeActionClass/bar/gee/wiz=neat/actionName
This action is treated just like:
/WebObjects/MyApp.woa/wpa/com.foo.SomeActionClass/actionName
Fields inherited from class com.webobjects.appserver._private.WOActionRequestHandler |
actionClassClass, actionClassName, CLASS_NOT_FOUND, defaultActionName, INSTANTIATION, INVALID_PATH, INVOCATION, shouldAddToStatistics |
Fields inherited from class com.webobjects.appserver.WORequestHandler |
DidHandleRequestNotification |
Constructor Summary |
ERXPathDirectActionRequestHandler()
Public constructor, just calls super |
ERXPathDirectActionRequestHandler(java.lang.String actionClassName,
java.lang.String defaultActionName,
boolean shouldAddToStatistics)
Public constructor, just calls super |
ERXPathDirectActionRequestHandler(java.lang.String actionClassName,
java.lang.String defaultActionName,
boolean shouldAddToStatistics,
boolean doUseClassName,
boolean doUseActionName)
Creates the request handler and lets you specify if the URLs assume and action class in front and action name in back. |
Method Summary |
static com.webobjects.foundation.NSDictionary<java.lang.String,java.lang.String> |
formValuesFromRequest(com.webobjects.appserver.WORequest request,
boolean useActionClass,
boolean useActionName)
Returns a dictionary similar to the normal request form value dict. |
com.webobjects.foundation.NSArray |
getRequestHandlerPathForRequest(com.webobjects.appserver.WORequest aRequest)
Modified version for getting the request handler path for a given
request. |
Methods inherited from class com.webobjects.appserver._private.WODirectActionRequestHandler |
allowsContentInputStream, defaultActionClassName, generateErrorResponse, generateRequestRefusal, handler, nullResponse, registerDidHandleActionRequestWithActionNamed, registerWillHandleActionRequest, setAllowsContentInputStream |
Methods inherited from class com.webobjects.appserver._private.WOActionRequestHandler |
_actionClassForName, _handleRequest, _putComponentsToSleepInContext, defaultDefaultActionName, defaultShouldAddToStatistics, getActionInstance, getRequestActionClassAndNameForPath, isSessionIDInRequest, toString |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
ERXPathDirectActionRequestHandler
public ERXPathDirectActionRequestHandler()
- Public constructor, just calls super
ERXPathDirectActionRequestHandler
public ERXPathDirectActionRequestHandler(java.lang.String actionClassName,
java.lang.String defaultActionName,
boolean shouldAddToStatistics)
- Public constructor, just calls super
- Parameters:
actionClassName
- action class namedefaultActionName
- action nameshouldAddToStatistics
- boolean to add to stats
ERXPathDirectActionRequestHandler
public ERXPathDirectActionRequestHandler(java.lang.String actionClassName,
java.lang.String defaultActionName,
boolean shouldAddToStatistics,
boolean doUseClassName,
boolean doUseActionName)
- Creates the request handler and lets you specify if the URLs assume and action class in front and action name in back.
This is useful when you have inner DA classes like SomeComponent$SomeAction and don't want this to appear in the URLs.
- Parameters:
actionClassName
- action class namedefaultActionName
- default action nameshouldAddToStatistics
- boolean if request should add to statsdoUseClassName
- if false, do not assume action class name in URLdoUseActionName
- if false, do not assume action name in URL
getRequestHandlerPathForRequest
public com.webobjects.foundation.NSArray getRequestHandlerPathForRequest(com.webobjects.appserver.WORequest aRequest)
- Modified version for getting the request handler path for a given
request.
- Overrides:
getRequestHandlerPathForRequest
in class com.webobjects.appserver._private.WODirectActionRequestHandler
- Parameters:
aRequest
- a given request
- Returns:
- array of request handler paths for a given request, truncates to
the first and last component if the number of components is
greater than 2, and tries to divine the meaning of paths when there
are only one or 2 path components.
formValuesFromRequest
public static com.webobjects.foundation.NSDictionary<java.lang.String,java.lang.String> formValuesFromRequest(com.webobjects.appserver.WORequest request,
boolean useActionClass,
boolean useActionName)
- Returns a dictionary similar to the normal request form value dict.
Translates /cgi-bin/.../wpa/foo/bar=2/baz into {foo = foo; bar = 2;
baz = baz}
- Parameters:
request
- request to parseuseActionClass
- true if first item should get ignoreduseActionName
- true if last item should get ignored
- Returns:
- the dictionary of form values
Copyright © 2002 – 2007 Project Wonder.