mx4j.tools.jython
Interface JythonRunnerMBean

All Known Implementing Classes:
JythonRunner

public interface JythonRunnerMBean

MBean interface.

Version:
$Revision: 1.4 $
Author:
Carlos Quiroz

Method Summary
 boolean getCacheScript()
          Returns whether the script should be kept in the cache.
 java.lang.String getNotificationType()
          Gets the specific notification type being listened
 ObjectName getObservedObject()
          Gets the object being observed by this MBean
 java.lang.String getScript()
          Returns the script as text.
 java.net.URL getScriptFile()
          Returns the URL pointing to the script source
 boolean getUseText()
          Indicates wether to use the script given in the ScripText variable or the one given in the script File.
 void runScript()
          Executes a given script.
 void setCacheScript(boolean useCache)
          Sets whether the script should be kept in the cache.
 void setNotificationType(java.lang.String notificationName)
          Sets the notification being listed.
 void setObservedObject(ObjectName targetMBeanName)
          Sets the object being observed by this MBean.
 void setScript(java.lang.String text)
          Sets the content of the script.
 void setScriptFile(java.net.URL file)
          Sets the script source as URL.
 

Method Detail

runScript

void runScript()
Executes a given script. If useText is true the text passed will be run as a script otherwise the script will be loaded from the URL an executed


getNotificationType

java.lang.String getNotificationType()
Gets the specific notification type being listened


setNotificationType

void setNotificationType(java.lang.String notificationName)
Sets the notification being listed. If null any notification will trigger the execution of the script. Otherwise only notifications matching notificationName will trigger it


setObservedObject

void setObservedObject(ObjectName targetMBeanName)
Sets the object being observed by this MBean. The MBean will register itself as a listener of targetMBeanName


getObservedObject

ObjectName getObservedObject()
Gets the object being observed by this MBean


getUseText

boolean getUseText()
Indicates wether to use the script given in the ScripText variable or the one given in the script File.


setScript

void setScript(java.lang.String text)
Sets the content of the script. If you want to use a file, use ScriptFile instead.


getScript

java.lang.String getScript()
Returns the script as text.


getScriptFile

java.net.URL getScriptFile()
Returns the URL pointing to the script source


setScriptFile

void setScriptFile(java.net.URL file)
Sets the script source as URL. If the cache script variable is true the file will be loaded only once, otherwise everytime the script is executed


getCacheScript

boolean getCacheScript()
Returns whether the script should be kept in the cache. If true, no further attempts to read the script will be done afterwards. By default is false


setCacheScript

void setCacheScript(boolean useCache)
Sets whether the script should be kept in the cache. If true, no further attempts to read the script will be done afterwards. By default is false



Copyright © 2001-2002 MX4J Team. All Rights Reserved.