|
MaltParser 1.0.2 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.maltparser.core.config.SingleMaltConfiguration
public class SingleMaltConfiguration
SingleMaltConfiguration handles deterministic parsing algorithms such as Nivre Arc-eager, Nivre Arc-standard, Covington Non-projective and Covington projective. It is possible to run the Single Malt configuration in six different modes:
Configuration
Field Summary | |
---|---|
protected ConfigurationDir |
configDir
|
protected org.apache.log4j.Logger |
configLogger
|
protected Integer |
containerIndex
|
protected SimpleDateFormat |
dateFormat
|
static int |
DEPROJ
|
protected long |
endTime
|
protected Guide |
guide
|
static int |
INFO
|
protected DataFormatSpecification |
inputFormat
|
static int |
LEARN
|
protected int |
mode
|
protected DataFormatSpecification |
outputFormat
|
static int |
PARSE
|
protected ParsingAlgorithm |
parsingAlgorithm
|
static int |
PROJ
|
protected DataReader |
reader
|
protected Sentence |
sentence
|
protected long |
startTime
|
protected SymbolTableHandler |
symbolTables
|
static int |
UNPACK
|
protected DataWriter |
writer
|
Constructor Summary | |
---|---|
SingleMaltConfiguration()
|
Method Summary | |
---|---|
void |
checkOptionDependency()
|
protected void |
deprojectivize()
|
void |
finalize()
|
org.apache.log4j.Logger |
getConfigLogger()
|
File |
getFile(String suffix)
|
BufferedWriter |
getInfoFileWriter()
|
InputStreamReader |
getInputStreamReader(String suffix)
|
int |
getMode()
|
String |
getName()
|
Object |
getOptionValue(String optiongroup,
String optionname)
|
protected String |
getOptionValueString(String optiongroup,
String optionname)
|
OutputStreamWriter |
getOutputStreamWriter(String suffix)
|
ParsingAlgorithm |
getParsingAlgorithm()
Returns the parsing algorithm in use |
Sentence |
getSentence()
Returns the sentence |
SymbolTableHandler |
getSymbolTables()
Returns the list of symbol tables |
protected void |
initConfigLogger()
|
protected void |
initConfigurationDir()
Creates a configuration directory and assign the configuration a name. |
void |
initialize(Integer containerIndex)
Configuration interface |
protected void |
initInput()
Initialize the input. |
protected void |
initMode()
Initialize the configuration mode |
protected void |
initOutput()
Initialize the output with a data writer |
protected void |
initParsingAlgorithm()
Initialize the parsing algorithm |
protected void |
learn()
Learns how to parse sentences in a language. |
protected void |
parse()
Parses sentences from the data source. |
boolean |
predict()
This method is used during parsing. |
boolean |
predictFromKBestList()
This method is used during parsing. |
void |
process()
|
protected void |
projectivize()
|
void |
setInstance(ParserAction parserAction)
This method is used during learning. |
String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final int LEARN
public static final int PARSE
public static final int UNPACK
public static final int INFO
public static final int PROJ
public static final int DEPROJ
protected org.apache.log4j.Logger configLogger
protected ConfigurationDir configDir
protected Integer containerIndex
protected ParsingAlgorithm parsingAlgorithm
protected Guide guide
protected Sentence sentence
protected DataFormatSpecification inputFormat
protected DataFormatSpecification outputFormat
protected DataReader reader
protected DataWriter writer
protected int mode
protected SymbolTableHandler symbolTables
protected long startTime
protected long endTime
protected SimpleDateFormat dateFormat
Constructor Detail |
---|
public SingleMaltConfiguration() throws MaltChainedException
MaltChainedException
Method Detail |
---|
public void initialize(Integer containerIndex) throws MaltChainedException
initialize
in interface Configuration
MaltChainedException
public void process() throws MaltChainedException
process
in interface Configuration
MaltChainedException
public void finalize() throws MaltChainedException
finalize
in interface Configuration
finalize
in class Object
MaltChainedException
public int getMode()
getMode
in interface Configuration
public OutputStreamWriter getOutputStreamWriter(String suffix) throws MaltChainedException
getOutputStreamWriter
in interface Configuration
MaltChainedException
public InputStreamReader getInputStreamReader(String suffix) throws MaltChainedException
getInputStreamReader
in interface Configuration
MaltChainedException
public File getFile(String suffix) throws MaltChainedException
getFile
in interface Configuration
MaltChainedException
public BufferedWriter getInfoFileWriter() throws MaltChainedException
getInfoFileWriter
in interface Configuration
MaltChainedException
public org.apache.log4j.Logger getConfigLogger()
getConfigLogger
in interface Configuration
public String getName()
getName
in interface Configuration
public Object getOptionValue(String optiongroup, String optionname) throws MaltChainedException
getOptionValue
in interface Configuration
MaltChainedException
protected String getOptionValueString(String optiongroup, String optionname) throws MaltChainedException
MaltChainedException
public void setInstance(ParserAction parserAction) throws MaltChainedException
setInstance
in interface Guidable
parserAction
-
MaltChainedException
public boolean predictFromKBestList() throws MaltChainedException
predictFromKBestList
in interface Guidable
MaltChainedException
public boolean predict() throws MaltChainedException
predict
in interface Guidable
MaltChainedException
public SymbolTableHandler getSymbolTables()
public Sentence getSentence()
public ParsingAlgorithm getParsingAlgorithm()
protected void learn() throws MaltChainedException
MaltChainedException
protected void parse() throws MaltChainedException
MaltChainedException
protected void projectivize() throws MaltChainedException
MaltChainedException
protected void deprojectivize() throws MaltChainedException
MaltChainedException
protected void initMode() throws MaltChainedException
MaltChainedException
protected void initConfigurationDir() throws MaltChainedException
MaltChainedException
protected void initConfigLogger() throws MaltChainedException
MaltChainedException
protected void initInput() throws MaltChainedException
MaltChainedException
protected void initOutput() throws MaltChainedException
MaltChainedException
protected void initParsingAlgorithm() throws MaltChainedException
MaltChainedException
public void checkOptionDependency() throws MaltChainedException
MaltChainedException
public String toString()
toString
in class Object
|
MaltParser 1.0.2 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |