Commit e09b3c83 e09b3c839bf9d67e6c09b166dbbfdaf78b74f609 by Christian Gerdes

Added new class, Registry, which contains a static list of monitors.

Changed Testrunner to use the Registry class instead.
1 parent 120dfc5a
package se.lil.om;
import java.util.ArrayList;
public class Registry {
private static ArrayList<OraMon> oraList = null;
public static ArrayList<OraMon> getList() {
if (oraList == null) {
oraList = new ArrayList<OraMon>();
}
return oraList;
}
}
......@@ -14,7 +14,8 @@ public class TestRunner {
public static void main(String[] args) throws Throwable{
// TODO Auto-generated method stub
ArrayList<OraMon> oraList = new ArrayList<OraMon>();
//ArrayList<OraMon> oraList = new ArrayList<OraMon>();
ArrayList<OraMon> oraList = Registry.getList();
OraMon mon1 = new OraMon("jdbc:oracle:thin:@//hostname:1521/SID1","system","passw0rd");
OraMon mon2 = new OraMon("jdbc:oracle:thin:@//hostname:1521/SID1","system","passw0rd");
......