coreMap = new HashMap();
coreMap = new WeakHashMap();
    static synchronized RhinoCore getRhinoCore(Application app) {        RhinoCore core = null;        if (coreMap == null) {            coreMap = new HashMap();        } else {            core = (RhinoCore) coreMap.get(app);        }        if (core == null) {            core = new RhinoCore(app);            coreMap.put(app, core);        }        return core;    }