public class IrtgInputCodec extends InputCodec<InterpretedTreeAutomaton>
interpretation keyword. They then
list a tree automaton, rule by rule, and annotate each rule with the homomorphic images
of the terminaly symbol on each interpretation, e.g. like this:
S! -> r1(NP,VP) [german] *(?1,?2) [english] *(?2,?1)
The exclamation mark after the S indicates that S is a final state of the tree automaton.
See any file in the examples subdirectory with the extension "irtg" for an example of an IRTG in this format.
| Constructor and Description |
|---|
IrtgInputCodec() |
| Modifier and Type | Method and Description |
|---|---|
static void |
addConstructorFeature(String id,
String classname,
List<String> arguments,
Map<String,FeatureFunction> features) |
static void |
addStaticFeature(String id,
String classname,
String methodname,
List<String> arguments,
Map<String,FeatureFunction> features) |
InterpretedTreeAutomaton |
read(InputStream is)
Reads an object from an input stream.
|
addOptions, getAllInputCodecs, getInputCodecByExtension, getInputCodecByName, getInputCodecByNameOrExtension, getInputCodecs, getMetadata, getOption, hasTrueOption, main, read, setOption, setProgressListenerpublic InterpretedTreeAutomaton read(InputStream is) throws IOException, CodecParseException
InputCodecread in class InputCodec<InterpretedTreeAutomaton>IOException - if an error occurred while reading
data from the input streamCodecParseException - if an error occurred while decoding
the input stream into an objectpublic static void addConstructorFeature(String id, String classname, List<String> arguments, Map<String,FeatureFunction> features) throws CodecParseException
CodecParseExceptionpublic static void addStaticFeature(String id, String classname, String methodname, List<String> arguments, Map<String,FeatureFunction> features) throws CodecParseException
CodecParseExceptionCopyright © 2017. All rights reserved.