// New implementation public JopSession(JopEngine engine, Object rootObject) { // Create a JopSessionRep object which class is not known by the compiler try { Class clazz = Class.forName("jpwr.jop.JopSessionRep"); try { sessionRep = clazz.newInstance(); } catch (InstantiationException e) { System.out.println("InstatiationException"); } catch (IllegalAccessException e) { System.out.println("IllegalAccessException"); } } catch (ClassNotFoundException e) { System.out.println("Class not found"); } ((JopSessionIfc) sessionRep).setSession(this); ((JopSessionIfc) sessionRep).setRoot(rootObject); ((JopSessionIfc) sessionRep).setEngine(engine); }