com.ibm.di.admin
Class RSInterfaceProxy

java.lang.Object
  extended by com.ibm.di.admin.RSInterfaceProxy
All Implemented Interfaces:
RSInterface

public class RSInterfaceProxy
extends Object
implements RSInterface


Field Summary
 MetamergeConfig mc
           
 
Constructor Summary
RSInterfaceProxy()
           
 
Method Summary
 void dump(Object o)
          Dumps the class and contents of an object to the log.
 void dumpEntry(Entry e)
          Dumps the contents of an Entry to the log.
 AttributeMapConfig getAttributeMap(String name)
          Returns the the "Attribute Map" entry for a named connector
 String getConfigPath()
          This method returns the current configuration file path
 Object getConfiguration(String name)
          Returns the entire table or a sub-section of the configuration file.
 ConnectorConfig getConnector(String name)
          Returns the the "Connector" entry for name
 FunctionConfig getFunction(String name)
          Returns the "FunctionConfig" entry for name
 LibraryConfig getLibraries()
          Returns all "Libraries"
 Object getLibrary(String name)
          Returns the the "Java Library" entry for name
 MetamergeConfig getMetamergeConfig()
          Returns the config object for this instance.
 String getNullBehavior()
          Return the null behavior value from the System.props
 String getNullBehaviorValue()
           
 String getNullDefinition()
          Return the null definition from the System.props
 String getNullDefinitionValue()
           
 ParserConfig getParser(String name)
          Returns the the "Parser" entry for name
 ScriptConfig getScript(String name)
          Returns the the "Script Library" entry for name
 String getSysProp(String name)
          Returns the value for a system property.
 AssemblyLineConfig getTask(String name)
          Returns the "AssemblyLine" entry
 EventHandlerConfig getTrigger(String name)
          Returns the "EventHandler" entry
static void init(MetamergeConfig config)
           
 void logmsg(String msg)
          Writes a message to the system log file
 void logmsg(String level, String msg)
          This method logs a message with the specified level to the system log.
 void persistConfiguration()
          This method saves the current configuration to disk.
 void reload()
          This method reloads the configuration file.
 AssemblyLine restartAL(String assemblyLine, String restartID)
          Start the AssemblyLine given by the parameter.
 void setConfigPath(String path)
          This method sets the current configuration file path.
 void setMetamergeConfig(MetamergeConfig config)
          Sets the given configuration to this instance.
 void shutdownServer()
          Set the shutdown request flag
 void shutdownServer(int aExitCode)
          Set the shutdown request flag and specifies exit code
 AssemblyLine startAL(String assemblyLine)
          Start the AssemblyLine given by the parameter.
 AssemblyLine startAL(String assemblyLine, Connector connector, Entry work)
          Start the AssemblyLine given by the parameter.
 AssemblyLine startAL(String assemblyLine, Object io)
          Start the AssemblyLine given by the parameter.
 Object startEventTrigger(String name, boolean checkEnabled)
          This method starts an EventHandler.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

mc

public MetamergeConfig mc
Constructor Detail

RSInterfaceProxy

public RSInterfaceProxy()
Method Detail

init

public static void init(MetamergeConfig config)

getConfiguration

public Object getConfiguration(String name)
Returns the entire table or a sub-section of the configuration file.

Specified by:
getConfiguration in interface RSInterface
Parameters:
name - Name of subsection or null
Returns:
The entire table (key == null) or section in table

getMetamergeConfig

public MetamergeConfig getMetamergeConfig()
Description copied from interface: RSInterface
Returns the config object for this instance.

Specified by:
getMetamergeConfig in interface RSInterface
Returns:
the configuration object of this instance.

setMetamergeConfig

public void setMetamergeConfig(MetamergeConfig config)
Description copied from interface: RSInterface
Sets the given configuration to this instance.

Specified by:
setMetamergeConfig in interface RSInterface
Parameters:
config - The configuration object to assign to the instance.

getTask

public AssemblyLineConfig getTask(String name)
Returns the "AssemblyLine" entry

Specified by:
getTask in interface RSInterface
Parameters:
name - The AssemblyLine name
Returns:
The configuration for the AssemblyLine

getConnector

public ConnectorConfig getConnector(String name)
Returns the the "Connector" entry for name

Specified by:
getConnector in interface RSInterface
Parameters:
name - The connector name
Returns:
The section from either the file configuration or the templates configuration

getTrigger

public EventHandlerConfig getTrigger(String name)
Returns the "EventHandler" entry

Specified by:
getTrigger in interface RSInterface
Parameters:
name - The EventHandler name
Returns:
The EventHandler section

getLibrary

public Object getLibrary(String name)
Returns the the "Java Library" entry for name

Specified by:
getLibrary in interface RSInterface
Parameters:
name - The java library name
Returns:
The section for name

getLibraries

public LibraryConfig getLibraries()
Returns all "Libraries"

Specified by:
getLibraries in interface RSInterface
Returns:
The entire list of Libraries

getParser

public ParserConfig getParser(String name)
Returns the the "Parser" entry for name

Specified by:
getParser in interface RSInterface
Parameters:
name - The parser name
Returns:
The section either the file configuration or the templates configuration

getScript

public ScriptConfig getScript(String name)
Returns the the "Script Library" entry for name

Specified by:
getScript in interface RSInterface
Parameters:
name - The script library name
Returns:
The section for name

getAttributeMap

public AttributeMapConfig getAttributeMap(String name)
Returns the the "Attribute Map" entry for a named connector

Specified by:
getAttributeMap in interface RSInterface
Parameters:
name - The connector name
Returns:
The attribute map section

getFunction

public FunctionConfig getFunction(String name)
                           throws Exception
Returns the "FunctionConfig" entry for name

Specified by:
getFunction in interface RSInterface
Parameters:
name - The name of the function
Returns:
The function config object
Throws:
Exception

getSysProp

public String getSysProp(String name)
Returns the value for a system property. The system properties include all Java system properties as well as Metamerge's own properties.

Specified by:
getSysProp in interface RSInterface
Parameters:
name - The system property name
Returns:
The value for the property

persistConfiguration

public void persistConfiguration()
                          throws Exception
This method saves the current configuration to disk.

Specified by:
persistConfiguration in interface RSInterface
Throws:
Exception

logmsg

public void logmsg(String msg)
Writes a message to the system log file

Specified by:
logmsg in interface RSInterface
Parameters:
msg - The message to log

logmsg

public void logmsg(String level,
                   String msg)
This method logs a message with the specified level to the system log.

Specified by:
logmsg in interface RSInterface
Parameters:
level - Loglevel.
msg - The message

dump

public void dump(Object o)
Dumps the class and contents of an object to the log. If this is an Entry, calls the dumpEntry method.

Specified by:
dump in interface RSInterface
Parameters:
o - The object to dump
See Also:
dumpEntry(com.ibm.di.entry.Entry)

dumpEntry

public void dumpEntry(Entry e)
Dumps the contents of an Entry to the log.

Specified by:
dumpEntry in interface RSInterface
Parameters:
e - The Entry object to dump
See Also:
Entry

restartAL

public AssemblyLine restartAL(String assemblyLine,
                              String restartID)
                       throws Exception
Start the AssemblyLine given by the parameter. See also the introduction to AssemblyLines.

Specified by:
restartAL in interface RSInterface
Parameters:
assemblyLine - The name identifying the AssemblyLine to start
restartID - The checkpoint identifier
Throws:
Exception

startAL

public AssemblyLine startAL(String assemblyLine)
                     throws Exception
Description copied from interface: RSInterface
Start the AssemblyLine given by the parameter. See also the introduction to AssemblyLines.

Specified by:
startAL in interface RSInterface
Parameters:
assemblyLine - The name identifying the AssemblyLine to start
Throws:
Exception

startAL

public AssemblyLine startAL(String assemblyLine,
                            Object io)
                     throws Exception
Start the AssemblyLine given by the parameter. See also the introduction to AssemblyLines.

Specified by:
startAL in interface RSInterface
Parameters:
assemblyLine - The name identifying the AssemblyLine to start
io - This Object could either be
1. an Entry, providing the initial work entry
2. a Connector, providing a runtime-provided Connector
3. a Vector 4. a TCB
Throws:
Exception

startAL

public AssemblyLine startAL(String assemblyLine,
                            Connector connector,
                            Entry work)
                     throws Exception
Start the AssemblyLine given by the parameter. See also the introduction to AssemblyLines.

Specified by:
startAL in interface RSInterface
Parameters:
assemblyLine - The name identifying the AssemblyLine to start
connector - The runtime-provided Connector
work - The initial work entry
Throws:
Exception

startEventTrigger

public Object startEventTrigger(String name,
                                boolean checkEnabled)
                         throws Exception
This method starts an EventHandler.

Specified by:
startEventTrigger in interface RSInterface
Parameters:
name - The EventHandler name
checkEnabled - If false, the autoStart flag is overridden
Returns:
The EventHandler thread object
Throws:
Exception

reload

public void reload()
            throws Exception
This method reloads the configuration file.

Specified by:
reload in interface RSInterface
Throws:
Exception

getConfigPath

public String getConfigPath()
This method returns the current configuration file path

Specified by:
getConfigPath in interface RSInterface
Returns:
The configuration file path as a string

setConfigPath

public void setConfigPath(String path)
This method sets the current configuration file path. This will be used when a persistConfiguration is requested.

Specified by:
setConfigPath in interface RSInterface
Parameters:
path - The new configuration path

shutdownServer

public void shutdownServer()
Set the shutdown request flag

Specified by:
shutdownServer in interface RSInterface

shutdownServer

public void shutdownServer(int aExitCode)
Set the shutdown request flag and specifies exit code

Specified by:
shutdownServer in interface RSInterface

getNullBehavior

public String getNullBehavior()
Return the null behavior value from the System.props

Specified by:
getNullBehavior in interface RSInterface

getNullBehaviorValue

public String getNullBehaviorValue()
Specified by:
getNullBehaviorValue in interface RSInterface

getNullDefinition

public String getNullDefinition()
Return the null definition from the System.props

Specified by:
getNullDefinition in interface RSInterface

getNullDefinitionValue

public String getNullDefinitionValue()
Specified by:
getNullDefinitionValue in interface RSInterface