Version: 1.1.1

ca.ucalgary.services
Class ACDService

java.lang.Object
  extended by javax.servlet.GenericServlet
      extended by javax.servlet.http.HttpServlet
          extended by org.biomoby.service.MobyServlet
              extended by ca.ucalgary.services.LegacyService
                  extended by ca.ucalgary.services.ACDService
All Implemented Interfaces:
Serializable, Remote, javax.servlet.Servlet, javax.servlet.ServletConfig

public class ACDService
extends LegacyService

A servlet that will read in an EMBOSS ACD file (which describes the command-line usage of a program in the suite) and publishes it as a MOBY service. MOBY XML data is converted to regular input to EMBOSS input via an XSLT stylesheet. EMBOSS results are conveted to MOBY datatypes using some built-in heuristics.

See Also:
Serialized Form

Field Summary
static String ACD_FILE_PARAM
           
static String EMBOSS_ADV_PARAMS_PARAM
           
static String EMBOSS_OUTPUT_PARAM
           
static String EMBOSS_PARAMS_PARAM
           
static String EMBOSS_ROOT_PARAM
           
 
Fields inherited from class ca.ucalgary.services.LegacyService
MOBY_RULES_DEFAULT_RESOURCE, MOBY_RULES_LOCATION_PARAM, TEXT_RULES_DEFAULT_RESOURCE, TEXT_RULES_LOCATION_PARAM
 
Fields inherited from class org.biomoby.service.MobyServlet
ADMIN_MODE, INIT_OUTPUT_BUFFER_SIZE, MOBY_AUTHORITATIVE_PARAM, MOBY_CENTRAL_URL_PARAM, MOBY_CONTACT_PARAM, MOBY_INPUT_PARAM, MOBY_OUTPUT_PARAM, MOBY_PROVIDER_URI_PARAM, MOBY_SECONDARYINPUT_PARAM, MOBY_SERVICE_DESC_PARAM, MOBY_SERVICENAME_PARAM, MOBY_SERVICETYPE_PARAM, MODE_HTTP_PARAM, RDF_MODE
 
Constructor Summary
ACDService()
           
 
Method Summary
 void configureServiceFromACDFile(MobyService service, File acdFile, boolean useAdvancedParams)
          Parses the ACD file and sets the MOBY signature parameters appropriately.
 MobyService createServiceFromConfig(javax.servlet.http.HttpServletRequest request)
          Determines the command-line program to execute when service requests come in, based on the values for the EMBOSS_ROOT_PARAM and ACD_FILE_PARAM parameters in the servlet configuration.
 void init()
          If you override this method, be sure to call super.init()
 void processRequest(MobyDataJob request, MobyDataJob result)
          Runs the command-line program specified by the servlet config, reformatting along the way.
 
Methods inherited from class org.biomoby.service.MobyServlet
destroy, doGet, doPost, getCentralImpl, getMobyContents, getServiceName, log, log, main, processRequests, setCoCInitParameter, setMainTerminationExit, stringToPrimaryDataTemplate, stringToSecondaryDataTemplate, validateArguments
 
Methods inherited from class javax.servlet.http.HttpServlet
service
 
Methods inherited from class javax.servlet.GenericServlet
getInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletInfo, getServletName, init, log
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

EMBOSS_ROOT_PARAM

public static final String EMBOSS_ROOT_PARAM
See Also:
Constant Field Values

EMBOSS_PARAMS_PARAM

public static final String EMBOSS_PARAMS_PARAM
See Also:
Constant Field Values

EMBOSS_ADV_PARAMS_PARAM

public static final String EMBOSS_ADV_PARAMS_PARAM
See Also:
Constant Field Values

EMBOSS_OUTPUT_PARAM

public static final String EMBOSS_OUTPUT_PARAM
See Also:
Constant Field Values

ACD_FILE_PARAM

public static final String ACD_FILE_PARAM
See Also:
Constant Field Values
Constructor Detail

ACDService

public ACDService()
Method Detail

init

public void init()
Description copied from class: MobyServlet
If you override this method, be sure to call super.init()

Overrides:
init in class MobyServlet

processRequest

public void processRequest(MobyDataJob request,
                           MobyDataJob result)
                    throws Exception
Runs the command-line program specified by the servlet config, reformatting along the way.

Overrides:
processRequest in class MobyServlet
Parameters:
request - the request to process, with params guaranteed to be of the type specified in the mobyService annotation, or values overriding the annjotation in a WAR file's WEB-INF/web.xml
Throws:
Exception

createServiceFromConfig

public MobyService createServiceFromConfig(javax.servlet.http.HttpServletRequest request)
                                    throws Exception
Determines the command-line program to execute when service requests come in, based on the values for the EMBOSS_ROOT_PARAM and ACD_FILE_PARAM parameters in the servlet configuration.

Overrides:
createServiceFromConfig in class LegacyService
Throws:
Exception

configureServiceFromACDFile

public void configureServiceFromACDFile(MobyService service,
                                        File acdFile,
                                        boolean useAdvancedParams)
                                 throws Exception
Parses the ACD file and sets the MOBY signature parameters appropriately.

Throws:
Exception

Version: 1.1.1

Submit a bug or feature
Generated: Sat May 29 04:26:35 EDT 2010