示例#1
0
  /* Main function calls native method*/
  public static void main(String[] args) {
    MyClass x = new MyClass();

    int i1 = 7;
    int i2 = 92343;

    System.out.println(x.add(i1));
    System.out.println(x.sub(i2));
  }
  public void start() {

    String configDir = Container.getInstance().getConfiguration().getConfigurationDirectory();

    ILookup lookup = lookupContainer.getDaoLookup();
    XMLUserObjectDAO usersDao = new XMLUserObjectDAO(configDir + USER_CONFIG_FILE);
    lookup.addContentObject(User.class, usersDao);

    if (Agent.getRMProperty("server.userManagement.initialize").equals("true")) {
      createDefaultUserEntries();
    }

    MyClass<AgentObject> myClass = new MyClass<AgentObject>();
    myClass.remove(new User());
    myClass.add(User.class);
  }