@CreoleResource(name="PythonPrResult",
comment="Language Resource to represent a PythonPr over corpus result.",
helpURL="")
public class PythonPrResult
extends gate.creole.AbstractLanguageResource
| Modifier and Type | Field and Description |
|---|---|
protected URL |
fileUrl |
protected Boolean |
logFeatures |
org.apache.log4j.Logger |
logger
Our logger instance.
|
| Constructor and Description |
|---|
PythonPrResult() |
| Modifier and Type | Method and Description |
|---|---|
URL |
getFileUrl()
Get the file URL.
|
Boolean |
getLogFeatures()
Get the log features flag.
|
Map<String,Object> |
getResultData()
Get the current result data stored in the features.
|
gate.Resource |
init()
Initialize resource.
|
protected void |
loadFromFile() |
void |
outputFeaturesToLog()
Log the current features to the logger.
|
protected void |
saveToFile() |
void |
setFileUrl(URL value)
Set the file URL
|
void |
setLogFeatures(Boolean value)
Set log features flag.
|
void |
setResultData(Map<String,Object> resultData)
Set or update the result data.
|
cleanup, getDataStore, getLRPersistenceId, getParent, isModified, setDataStore, setLRPersistenceId, setParent, synccheckParameterValues, flushBeanInfoCache, forgetBeanInfo, getBeanInfo, getInitParameterValues, getInitParameterValues, getName, getParameterValue, getParameterValue, getParameterValues, removeResourceListeners, setName, setParameterValue, setParameterValue, setParameterValues, setParameterValues, setResourceListeners, toStringclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitpublic transient org.apache.log4j.Logger logger
protected Boolean logFeatures
protected URL fileUrl
@Optional @CreoleParameter(comment="If true, log the current features whenever the result is updated.") public void setLogFeatures(Boolean value)
value - flagpublic Boolean getLogFeatures()
@Optional @CreoleParameter(comment="File to use for saving/loading the result. Nothing saved/loaded if missing.") public void setFileUrl(URL value)
value - file URLpublic URL getFileUrl()
public gate.Resource init()
init in interface gate.Resourceinit in class gate.creole.AbstractResourceprotected void saveToFile()
protected void loadFromFile()
public void outputFeaturesToLog()
public void setResultData(Map<String,Object> resultData)
resultData - the result data to setCopyright © 2021 GATE Team. All rights reserved.