inpro.irmrsc.util
Class RMRSLoader

java.lang.Object
  extended by inpro.irmrsc.util.RMRSLoader

public class RMRSLoader
extends java.lang.Object

A helper class to load the semantic macros, the mapping from syntactic rules to semantic macros and the POS-tag lexicon.

Author:
Andreas Peldszus

Constructor Summary
RMRSLoader()
           
 
Method Summary
static java.util.List<SemanticMacro> loadMacros(java.net.URL url)
          Loads a xml specification of semantic macros from a given url.
static java.util.Map<java.lang.String,java.lang.String> loadRules(java.net.URL url)
          Loads a xml specification of the mapping between syntactic rules IDs and semantic macro longnames.
static java.util.Map<java.lang.String,Variable.Type> loadTagLexicon(java.net.URL url)
          Loads a xml specification of the mapping between POS-tags and the basic semantic types that lexical predicate formulas of words with this tags receive.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RMRSLoader

public RMRSLoader()
Method Detail

loadMacros

public static java.util.List<SemanticMacro> loadMacros(java.net.URL url)
Loads a xml specification of semantic macros from a given url.

Parameters:
url - the specified url of the xml to load
Returns:
the list of semantic macros

loadRules

public static java.util.Map<java.lang.String,java.lang.String> loadRules(java.net.URL url)
Loads a xml specification of the mapping between syntactic rules IDs and semantic macro longnames.

Parameters:
url - the specified url of the xml to load
Returns:
the mapping

loadTagLexicon

public static java.util.Map<java.lang.String,Variable.Type> loadTagLexicon(java.net.URL url)
Loads a xml specification of the mapping between POS-tags and the basic semantic types that lexical predicate formulas of words with this tags receive.

Parameters:
url - the specified url of the xml to load
Returns:
the mapping from POS-tags as Strings to Variable.Types