ch.uzh.ifi.attempto.base
Class APE

java.lang.Object
  extended by ch.uzh.ifi.attempto.base.APE

public class APE
extends java.lang.Object

This class is used to get an instance of ACEParser by parameters. Following parameters are recognized: - apetype Specify the type of APE, should be one of "local", "socket" and "webservice". - apecommand Location of ape.exe, used by APELocal when apetype is "local". - apehost Host name of APE socket server, used by APESocket when apetype is "socket". - apeport Port number of APE socket server, used by APESocket whe apetype is "socket". - apewebservice APE webservice URL, use by APEWebservice when apetype is "webservice".

Author:
Yu Changyuan

Constructor Summary
APE()
           
 
Method Summary
static ch.uzh.ifi.attempto.ape.ACEParser getAPELocal(java.lang.String apeCommand)
          Get a APELocal instance with specified ape.exe location
static ch.uzh.ifi.attempto.ape.ACEParser getAPESocket(java.lang.String host, int port)
          Get a APESocket instance with specified host and port
static ch.uzh.ifi.attempto.ape.ACEParser getAPEWebservice(java.lang.String url)
          Get a APEWebservice instance with specified host and port
static ch.uzh.ifi.attempto.ape.ACEParser getParser()
          Get a ACEParser instance with default parameters.
static ch.uzh.ifi.attempto.ape.ACEParser getParser(java.util.Map<java.lang.String,java.lang.String> parameters)
          Get a ACEParser instance by parameters.
static void setParameters(java.util.Map<java.lang.String,java.lang.String> parameters)
          Set default parameters.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

APE

public APE()
Method Detail

getParser

public static ch.uzh.ifi.attempto.ape.ACEParser getParser(java.util.Map<java.lang.String,java.lang.String> parameters)
Get a ACEParser instance by parameters.

Parameters:
parameters - The parameters set in servlet web.xml.
Returns:
The ACEParser instance.

getParser

public static ch.uzh.ifi.attempto.ape.ACEParser getParser()
Get a ACEParser instance with default parameters.

Returns:
The ACEParser instance.

setParameters

public static void setParameters(java.util.Map<java.lang.String,java.lang.String> parameters)
Set default parameters.

Parameters:
parameters - The parameters to set.

getAPELocal

public static ch.uzh.ifi.attempto.ape.ACEParser getAPELocal(java.lang.String apeCommand)
Get a APELocal instance with specified ape.exe location

Parameters:
apeCommand - The location of ape.exe.
Returns:
The APELocal instance.

getAPESocket

public static ch.uzh.ifi.attempto.ape.ACEParser getAPESocket(java.lang.String host,
                                                             int port)
Get a APESocket instance with specified host and port

Parameters:
host - The host of APE socket server.
port - The port of APE socket server.
Returns:
The APESocket instance.

getAPEWebservice

public static ch.uzh.ifi.attempto.ape.ACEParser getAPEWebservice(java.lang.String url)
Get a APEWebservice instance with specified host and port

Parameters:
url - The URL of APE webservice.
Returns:
The APEWebservice instance.


Copyright 2008-2012, AceWiki developers