01: /*
02: * init.java
03: *
04: * Copyright (c) 2006 Sun Microsystems, Inc. All Rights Reserved.
05: *
06: * See the file "LICENSE.txt" for information on usage and redistribution
07: * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
08: */
09: package pnuts.jmx;
10:
11: import pnuts.lang.Runtime;
12: import pnuts.lang.Package;
13: import pnuts.lang.Context;
14: import pnuts.ext.ModuleBase;
15:
16: /**
17: * Initialization of the pnuts.jmx module
18: */
19: public class init extends ModuleBase {
20:
21: static String[] javaFunctions = {};
22:
23: static String[] files = { "pnuts/jmx/functions" };
24:
25: static String[][] functions = { { "mbeanConnection", "mbeanServer",
26: "dynamicMBean" } };
27:
28: static String[] requiredModules = { "pnuts.lib" };
29:
30: protected String[] getRequiredModules() {
31: return requiredModules;
32: }
33:
34: public Object execute(Context context) {
35: for (int i = 0; i < files.length; i++) {
36: autoload(functions[i], files[i], context);
37: }
38: return null;
39: }
40: }
|