public class StaticContentAction extends AbstractAction
| Modifier and Type | Field and Description |
|---|---|
protected java.util.ArrayList<java.util.regex.Pattern> |
forbidden |
private org.eclipse.jetty.http.MimeTypes |
mimeTypes |
protected java.lang.String |
mountPoint |
protected java.lang.String |
urlPrefix |
actionParamKey, handledActions, httpHeaders, isDefaultAction, replacements, replacementsInitialized, servletModuleengine, initScript, persistentObjects, scriptManager, startScript, stopScriptautoStart, isInitialized, isRunning, logging, loggingModule, moduleManager| Constructor and Description |
|---|
StaticContentAction() |
| Modifier and Type | Method and Description |
|---|---|
java.util.Collection<Module> |
getDependencies(ModuleManager manager)
Returns all the modules this module depends on.
|
protected java.lang.String |
getLocalPath(javax.servlet.http.HttpServletRequest req) |
boolean |
handleAction(javax.servlet.http.HttpServletRequest req,
javax.servlet.http.HttpServletResponse resp,
ModulesServlet.HttpMethod method,
java.lang.String action,
User user)
Handles this action.
|
void |
init(ModuleManager manager,
java.util.HashMap<java.lang.String,java.lang.Object> settings)
Initialises the module.
|
boolean |
isHandleAction(javax.servlet.http.HttpServletRequest req,
javax.servlet.http.HttpServletResponse resp,
ModulesServlet.HttpMethod method)
Checks if this action handler will try to handle the given action
without handling it yet or causing any side effects.
|
protected boolean |
returnFile(javax.servlet.http.HttpServletResponse response,
java.io.File f) |
addHandledAction, doReplacements, handleRequest, setActionParamKey, setHttpHeaders, start, stopgetScriptEngineisInitialized, isRunning, requireLogging, toStringprotected java.lang.String mountPoint
protected java.util.ArrayList<java.util.regex.Pattern> forbidden
protected java.lang.String urlPrefix
private org.eclipse.jetty.http.MimeTypes mimeTypes
public java.util.Collection<Module> getDependencies(ModuleManager manager) throws ModuleException
ModulegetDependencies in interface ModulegetDependencies in class AbstractActionmanager - The module manager handling this module.ModuleExceptionpublic void init(ModuleManager manager, java.util.HashMap<java.lang.String,java.lang.Object> settings) throws ModuleException
ModuleInitialises the module. After constructor, this is the first method called in the life cycle of a module. It should not perform anything time consuming or anything with notable outside side effects. It should only read the parameters and initialise the module so that it can later be started. Note that a module being initialised doesn't mean that it necessarily will ever be started.
A ModuleException may be thrown if something vital is missing from the parameters or they are not sensible. In some cases you may not want to throw an exception even if vital initialisation information is missing. If, for example, it is possible that the module is initialised in some other way between the init and the start method calls. A ModuleException may also be thrown at the start method if the module is still not initialised.
init in interface Moduleinit in class AbstractActionmanager - The module manager handling this module. You may keep a
reference to it if needed.ModuleExceptionprotected java.lang.String getLocalPath(javax.servlet.http.HttpServletRequest req)
protected boolean returnFile(javax.servlet.http.HttpServletResponse response,
java.io.File f)
throws java.io.IOException
java.io.IOExceptionpublic boolean isHandleAction(javax.servlet.http.HttpServletRequest req,
javax.servlet.http.HttpServletResponse resp,
ModulesServlet.HttpMethod method)
ActionHandlerisHandleAction in interface ActionHandlerisHandleAction in class AbstractActionreq - The HTTP request.resp - The HTTP response.method - The HTTP method of the request.public boolean handleAction(javax.servlet.http.HttpServletRequest req,
javax.servlet.http.HttpServletResponse resp,
ModulesServlet.HttpMethod method,
java.lang.String action,
User user)
throws javax.servlet.ServletException,
java.io.IOException,
ActionException
AbstractActionhandleAction in class AbstractActionreq - The HTTP Request.resp - The HTTP response.method - The HTTP method of the request.action - The parsed action id.user - The logged in user, or null if not applicable.javax.servlet.ServletExceptionjava.io.IOExceptionActionExceptionCopyright 2004-2015 Wandora Team