DEADSOFTWARE

JVM: Добавлена инициализация модулей
[dsw-obn.git] / rtl / Launcher.java
index 220f671f5dde0d0efeb9f61f29dd4878be32ff29..5077fa884a1620022ba77acc0ca4f32b1d7467a2 100644 (file)
@@ -1,6 +1,17 @@
-class Launcher {
+import java.lang.reflect.*;
+
+class Launcher
+{
        public static void main(String[] args)
-       throws ClassNotFoundException, InstantiationException, IllegalAccessException {
-               Class.forName(args[0]).newInstance();;
+               throws
+                       ClassNotFoundException,
+                       InstantiationException,
+                       IllegalAccessException,
+                       NoSuchMethodException,
+                       InvocationTargetException
+       {
+               Class<?> module = Class.forName(args[0]);
+               Method begin = module.getMethod("BEGIN");
+               begin.invoke(null);
        }
 }