|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectgate.util.AbstractFeatureBearer
gate.creole.AbstractResource
gate.creole.AbstractProcessingResource
gate.creole.AbstractLanguageAnalyser
gate.creole.tokeniser.chinesetokeniser.ChineseTokeniser
Title: ChineseTokeniser.java
Description: This class is a wrapper for segmenter.
Tokenises a Chinese document using the Chinesse segmenter
Nested Class Summary |
Nested classes inherited from class gate.creole.AbstractProcessingResource |
AbstractProcessingResource.InternalStatusListener, AbstractProcessingResource.IntervalProgressListener |
Field Summary | |
private String |
annotationSetName
|
private int |
charform
|
private Document |
document
The name of the sourceFile |
private String |
encoding
The name of the encoding used |
private Boolean |
generateSpaceTokens
Boolean value which says if tokeniser has to generate the spack tokens |
private URL |
rulesURL
Rules for the simple tokeniser |
private Boolean |
runSegmenter
Boolean value which states if segmenter should run |
private Segmenter |
segmenter
Instance of segmenter |
private Document |
tempDoc
Temporary document |
private SimpleTokeniser |
tokeniser
Instance of Simple Tokenizer |
Fields inherited from class gate.creole.AbstractLanguageAnalyser |
corpus |
Fields inherited from class gate.creole.AbstractProcessingResource |
interrupted |
Fields inherited from class gate.creole.AbstractResource |
name |
Fields inherited from class gate.util.AbstractFeatureBearer |
features |
Constructor Summary | |
ChineseTokeniser()
Default Constructor |
Method Summary | |
void |
execute()
This method gets executed whenever user clicks on the Run button available in the GATE gui. |
String |
getAnnotationSetName()
Returns the provided annotationset name |
Document |
getDocument()
Returns the document under process |
String |
getEncoding()
Returns the document under process |
Boolean |
getGenerateSpaceTokens()
Gets the boolean parameter which states if segmenter should produce the space tokens |
URL |
getRulesURL()
Returns the URL of the file, which contains rules for the tokeniser |
Boolean |
getRunSegmenter()
Gets the boolean parameter which states if segmenter should run |
Resource |
init()
Initialise this resource, and return it. |
void |
reInit()
This method reInitialises the segmenter |
void |
setAnnotationSetName(String name)
AnnotationSet name |
void |
setDocument(Document document)
Sets the document to be processed |
void |
setEncoding(String encoding)
Sets the encoding to be used. |
void |
setGenerateSpaceTokens(Boolean value)
Sets the boolean parameter which states if segmenter should produce the space tokens |
void |
setRulesURL(URL rules)
URL for the file, which contains rules to be given to the tokeniser |
void |
setRunSegmenter(Boolean runSegmenter)
Sets the boolean parameter which states if segmenter should run |
Methods inherited from class gate.creole.AbstractLanguageAnalyser |
getCorpus, setCorpus |
Methods inherited from class gate.creole.AbstractProcessingResource |
addProgressListener, addStatusListener, cleanup, fireProcessFinished, fireProgressChanged, fireStatusChanged, interrupt, isInterrupted, removeProgressListener, removeStatusListener |
Methods inherited from class gate.creole.AbstractResource |
checkParameterValues, getBeanInfo, getName, getParameterValue, getParameterValue, removeResourceListeners, setName, setParameterValue, setParameterValue, setParameterValues, setParameterValues, setResourceListeners |
Methods inherited from class gate.util.AbstractFeatureBearer |
getFeatures, setFeatures |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface gate.Resource |
cleanup, getParameterValue, setParameterValue, setParameterValues |
Methods inherited from interface gate.util.FeatureBearer |
getFeatures, setFeatures |
Methods inherited from interface gate.util.NameBearer |
getName, setName |
Methods inherited from interface gate.Executable |
interrupt, isInterrupted |
Field Detail |
private Segmenter segmenter
private String encoding
private Document document
private Document tempDoc
private SimpleTokeniser tokeniser
private Boolean runSegmenter
private Boolean generateSpaceTokens
private URL rulesURL
private String annotationSetName
private int charform
Constructor Detail |
public ChineseTokeniser()
Method Detail |
public Resource init() throws ResourceInstantiationException
Resource
init
in interface Resource
init
in class AbstractProcessingResource
ResourceInstantiationException
public void reInit() throws ResourceInstantiationException
reInit
in interface ProcessingResource
reInit
in class AbstractProcessingResource
ResourceInstantiationException
public void execute() throws ExecutionException
execute
in interface Executable
execute
in class AbstractProcessingResource
ExecutionException
public void setRunSegmenter(Boolean runSegmenter)
runSegmenter
- public Boolean getRunSegmenter()
public void setGenerateSpaceTokens(Boolean value)
public Boolean getGenerateSpaceTokens()
public void setDocument(Document document)
setDocument
in interface LanguageAnalyser
setDocument
in class AbstractLanguageAnalyser
document
- - document to be processedpublic Document getDocument()
getDocument
in interface LanguageAnalyser
getDocument
in class AbstractLanguageAnalyser
public void setEncoding(String encoding)
encoding
- the encoding.public String getEncoding()
public void setRulesURL(URL rules)
rules
- public URL getRulesURL()
URL
value.public void setAnnotationSetName(String name)
name
- Name of the annotationpublic String getAnnotationSetName()
String
value.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |