org.ow2.weblab.service.gate
Class GateService
java.lang.Object
org.ow2.weblab.service.gate.GateService
- All Implemented Interfaces:
- org.weblab_project.services.analyser.Analyser
public class GateService
- extends java.lang.Object
- implements org.weblab_project.services.analyser.Analyser
This class is a WebService calling Gate with different configurations.
It initializes gate once with a gapp configuration and implements a corpus pipeline
- Author:
- khelif, ymombrun
|
Constructor Summary |
GateService()
Default constructor using DEFAULT_GAPP_FILE as defaultGappFile and DEFAULT_SERVICE_URI as serviceURI |
GateService(java.io.File defaultGappFile)
|
GateService(java.io.File defaultGappFile,
java.io.File pluginsPath)
|
GateService(java.io.File defaultGappFile,
java.io.File pluginsPath,
java.lang.String defaultLanguage)
|
|
Method Summary |
protected java.util.List<org.weblab_project.core.model.text.Text> |
checkParameters(org.weblab_project.services.analyser.types.ProcessArgs args)
|
org.weblab_project.services.analyser.types.ProcessReturn |
process(org.weblab_project.services.analyser.types.ProcessArgs args)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DEFAULT_LANGUAGE
public static final java.lang.String DEFAULT_LANGUAGE
- See Also:
- Constant Field Values
GateService
public GateService()
throws java.io.IOException
- Default constructor using DEFAULT_GAPP_FILE as defaultGappFile and DEFAULT_SERVICE_URI as serviceURI
- Throws:
java.io.IOException - If the default gapp file cannot be found in classpath resources or If Gate home cannot be found in classpath resource
GateService
public GateService(java.io.File defaultGappFile)
throws java.io.IOException
- Parameters:
defaultGappFile - The defaultGappFile
- Throws:
java.io.IOException - If Gate home cannot be found in classpath resource
GateService
public GateService(java.io.File defaultGappFile,
java.io.File pluginsPath)
throws java.io.IOException
- Parameters:
defaultGappFile - pluginsPath -
- Throws:
java.io.IOException - If Gate home cannot be found in classpath resource
GateService
public GateService(java.io.File defaultGappFile,
java.io.File pluginsPath,
java.lang.String defaultLanguage)
throws java.io.IOException
- Parameters:
defaultGappFile - pluginsPath - defaultLanguage -
- Throws:
java.io.IOException - If Gate home cannot be found in classpath resource
process
public org.weblab_project.services.analyser.types.ProcessReturn process(org.weblab_project.services.analyser.types.ProcessArgs args)
throws org.weblab_project.services.analyser.ProcessException
- Specified by:
process in interface org.weblab_project.services.analyser.Analyser
- Throws:
org.weblab_project.services.analyser.ProcessException
checkParameters
protected java.util.List<org.weblab_project.core.model.text.Text> checkParameters(org.weblab_project.services.analyser.types.ProcessArgs args)
throws org.weblab_project.services.analyser.ProcessException
- Parameters:
args - The ProcessArgs
- Returns:
- The list of Text contained by the Resource in args.
- Throws:
org.weblab_project.services.analyser.ProcessException - For any reason preventing the retrieval of text unit to be done.
Copyright © 2004-2010. All Rights Reserved.