public class LinkSpecParser
extends java.lang.Object
implements org.ai_heuristic.def.ParserDef
LinkSpec script file and parse it to or from XML.| Constructor and Description |
|---|
LinkSpecParser()
Create a new instance of LinkSpecParser.
|
| Modifier and Type | Method and Description |
|---|---|
java.lang.Object |
parse(org.licas_xml.abs.Element toParse)
Parse the linking spec config back into a
LinkSpec object. |
static java.util.HashMap |
parseOptions(org.licas_xml.abs.Element hashXml)
Parse the service script list of options as key-value pairs.
|
org.licas_xml.abs.Element |
serialize(java.lang.Object toSerialize)
Serialize the link spec script specification into XML.
|
static org.licas_xml.abs.Element |
serializeOptions(java.util.HashMap optionsList)
Serialize the list of options into an ML-based description.
|
public org.licas_xml.abs.Element serialize(java.lang.Object toSerialize)
throws java.lang.Exception
serialize in interface org.ai_heuristic.def.ParserDeftoSerialize - the LinkSpec object to serialize.java.lang.Exception - any error.public java.lang.Object parse(org.licas_xml.abs.Element toParse)
throws java.lang.Exception
LinkSpec object.parse in interface org.ai_heuristic.def.ParserDeftoParse - the XML-based description.java.lang.Exception - any error.public static org.licas_xml.abs.Element serializeOptions(java.util.HashMap optionsList)
throws java.lang.Exception
optionsList - the list of options to serialize.java.lang.Exception - any error.public static java.util.HashMap parseOptions(org.licas_xml.abs.Element hashXml)
hashXml - an XML-based description of the options list.