toolbox.web.actions.wsil
Class Dir2WSILAction

Package class diagram package Dir2WSILAction
java.lang.Object
  extended by toolbox.web.BaseWebAction
      extended by toolbox.web.actions.wsil.Dir2WSILAction
All Implemented Interfaces:
WebAction

public class Dir2WSILAction
extends BaseWebAction
implements WebAction

Action implementation to generate a WSIL document based on the contents of a directory.

An example configuration can be found at etc/dir2wsil_web_config.xml in the toolbox distribution. The WSIL template can be found at share/freemarker/dir2wsil.ftl in the toolbox distribution.


Constructor Summary
Dir2WSILAction()
          Default constructor
 
Method Summary
 void create(java.lang.String name, Controller controller, javax.servlet.ServletContext context)
          Override the create method to initialise the WSIL data.
 void execute(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, javax.servlet.ServletContext context)
          Populate the request with the WSIL and server information.
 
Methods inherited from class toolbox.web.BaseWebAction
dispatch, getBodyAsDocument, getBodyAsString, getDisplayTemplate, getFailureTemplate, getForeignContext, getGlobalProperty, getMessage, getName, getProperties, getProperty, getResource, getResourceBundle, getResourceString, getResourceString, getResourceString, getResourceString, getResourceString, getSuccessTemplate, getTemplate, getValidator, logConfig, logFine, logFiner, logFinest, logInfo, logSevere, logWarning, redirect, split
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Dir2WSILAction

public Dir2WSILAction()
Default constructor

Method Detail

create

public void create(java.lang.String name,
                   Controller controller,
                   javax.servlet.ServletContext context)
            throws ConfException
Override the create method to initialise the WSIL data.

Specified by:
create in interface WebAction
Overrides:
create in class BaseWebAction
Parameters:
name - Action name.
controller - Controller that created this action.
context - Current servlet context.
Throws:
ConfException - if the action cannot be created.

execute

public void execute(javax.servlet.http.HttpServletRequest request,
                    javax.servlet.http.HttpServletResponse response,
                    javax.servlet.ServletContext context)
             throws javax.servlet.ServletException,
                    java.io.IOException
Populate the request with the WSIL and server information.

Specified by:
execute in interface WebAction
Parameters:
request - HTTP request received.
response - HTTP response to be used.
context - Current servlet context.
Throws:
javax.servlet.ServletException
java.io.IOException