gate.util.web
Class WebAnnie

java.lang.Object
  extended bygate.util.web.WebAnnie

public class WebAnnie
extends Object

This class is designed to demonstrate ANNIE in a web context. It should be called from either a servlet or a JSP.


Field Summary
static String ANNIE_CONTROLLER_KEY
           
private  SerialAnalyserController annieController
          The Corpus Pipeline application to contain ANNIE
private  String filePath
           
static String GATE_INIT_KEY
           
 
Constructor Summary
WebAnnie()
           
 
Method Summary
private  void initAnnie()
          Initialise the ANNIE system.
 String process(javax.servlet.ServletContext app, String url, String[] annotations)
          This method should be called from a servlet or JSP.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

GATE_INIT_KEY

public static final String GATE_INIT_KEY
See Also:
Constant Field Values

ANNIE_CONTROLLER_KEY

public static final String ANNIE_CONTROLLER_KEY
See Also:
Constant Field Values

annieController

private SerialAnalyserController annieController
The Corpus Pipeline application to contain ANNIE


filePath

private String filePath
Constructor Detail

WebAnnie

public WebAnnie()
Method Detail

initAnnie

private void initAnnie()
                throws GateException
Initialise the ANNIE system. This creates a "corpus pipeline" application that can be used to run sets of documents through the extraction system.

Throws:
GateException

process

public String process(javax.servlet.ServletContext app,
                      String url,
                      String[] annotations)
               throws GateException,
                      IOException
This method should be called from a servlet or JSP.

Parameters:
app - The current servlet context, eg the JSP implicit variable "application"
url - The url of the file to be analysed
annotations - An array of annotations
Throws:
GateException
IOException