|
MaltParser 1.0.0 | |||||||||
| 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 four 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 ConfigurationMaltChainedException
public void process()
throws MaltChainedException
process in interface ConfigurationMaltChainedException
public void finalize()
throws MaltChainedException
finalize in interface Configurationfinalize in class ObjectMaltChainedExceptionpublic int getMode()
getMode in interface Configuration
public OutputStreamWriter getOutputStreamWriter(String suffix)
throws MaltChainedException
getOutputStreamWriter in interface ConfigurationMaltChainedException
public InputStreamReader getInputStreamReader(String suffix)
throws MaltChainedException
getInputStreamReader in interface ConfigurationMaltChainedException
public File getFile(String suffix)
throws MaltChainedException
getFile in interface ConfigurationMaltChainedException
public BufferedWriter getInfoFileWriter()
throws MaltChainedException
getInfoFileWriter in interface ConfigurationMaltChainedExceptionpublic org.apache.log4j.Logger getConfigLogger()
getConfigLogger in interface Configurationpublic String getName()
getName in interface Configuration
public Object getOptionValue(String optiongroup,
String optionname)
throws MaltChainedException
getOptionValue in interface ConfigurationMaltChainedException
protected String getOptionValueString(String optiongroup,
String optionname)
throws MaltChainedException
MaltChainedException
public void setInstance(ParserAction parserAction)
throws MaltChainedException
setInstance in interface GuidableparserAction -
MaltChainedException
public boolean predictFromKBestList()
throws MaltChainedException
predictFromKBestList in interface GuidableMaltChainedException
public boolean predict()
throws MaltChainedException
predict in interface GuidableMaltChainedExceptionpublic 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
MaltChainedExceptionpublic String toString()
toString in class Object
|
MaltParser 1.0.0 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||