Shark中的ToolAgent用法-JavaClassToolAgent
2005-08-01 16:40
411 查看
Shark帮助文档中原文如下:
JavaClassToolAgent - This tool agent executes Java classes, by calling its static method called "execute". When calling this tool agent's invokeApplication() method, the application name parameter should be the full name of the class that should be executed by this tool agent. So far, we defined a few classes that execute simple arithmetic operation, generation of random number, and one that performs waiting. There are also two classes contributed to by Paloma Trigueros Cabezon, and they can be used to use this tool agent to send mails.
This tool agent is able to "understand" the extended attribute with the following name:
AppName - value of this attribute should represent the class name to be executed.
首先要知道这是一种把一个类来作为一个应用的方法,具体做法如下:
1、创建一个新类javaclass.java,类中必须包含一个静态方法execute,该方法即为希望该类完成的行为。
2、编译类文件为javaclass.class,并放入:安装路径/lib/engine/sharktoolagent-standard.jar中。
3、这样在编辑process时,就可以应用这些自己编写的类了。可以定义application了,注意定义两个可扩展属性:ToolAgentClass=JavaClassToolAgent,AppName=类名(javaclass)。
JavaClassToolAgent - This tool agent executes Java classes, by calling its static method called "execute". When calling this tool agent's invokeApplication() method, the application name parameter should be the full name of the class that should be executed by this tool agent. So far, we defined a few classes that execute simple arithmetic operation, generation of random number, and one that performs waiting. There are also two classes contributed to by Paloma Trigueros Cabezon, and they can be used to use this tool agent to send mails.
This tool agent is able to "understand" the extended attribute with the following name:
AppName - value of this attribute should represent the class name to be executed.
首先要知道这是一种把一个类来作为一个应用的方法,具体做法如下:
1、创建一个新类javaclass.java,类中必须包含一个静态方法execute,该方法即为希望该类完成的行为。
2、编译类文件为javaclass.class,并放入:安装路径/lib/engine/sharktoolagent-standard.jar中。
3、这样在编辑process时,就可以应用这些自己编写的类了。可以定义application了,注意定义两个可扩展属性:ToolAgentClass=JavaClassToolAgent,AppName=类名(javaclass)。
相关文章推荐
- Shark中的ToolAgent用法-RuntimeApplicationToolAgent
- Shark中的ToolAgent用法-JavaScriptToolAgent
- java中Class.getResource用法
- Java5泛型的用法,T.class的获取和为擦拭法站台
- java Class.getSimpleName() 详解及用法
- java中Class.getResource用法
- java中Class.getResource用法(转)
- java中Class.getResource用法
- java中Class.getResource用法
- Java5泛型的用法,T.class的获取和为擦拭法站台
- If the only tool you have is Java, everything looks like a class
- java中Class.getResource用法
- java的classpath设置与-D命令参数的用法
- Java.lang.Class.getDeclaredMethod()方法用法
- java反射之Class初级用法
- Java Classloader机制用法代码解析
- [泛型经典]Java5泛型的用法,T.class的获取和为擦拭法站台
- Picked up JAVA_TOOL_OPTIONS: -javaagent:/usr/share/java/jayatanaag.jar的解决办法
- Java Decompiler Tool(Java class文件反汇编工具)
- Picked up JAVA_TOOL_OPTIONS: -javaagent:/usr/share/java/jayatanaag.jar