public void read(JmeImporter e) throws IOException { destroy(); // System.out.println("Test"); instances = new SafeArrayList(Type.class, e.getCapsule(this).readSavableArrayList("instances", null)); hash = new Hashtable<String, Type>(); if (instances != null) { // System.out.println("LALALA"); for (Type t : instances.getArray()) { hash.put(t.getId(), t); // System.out.println("LALALA"+ t.getId()); } } myclass = (e.getCapsule(this).readSavable("myclass", null)).getClass(); }
public void addType(Type t) { hash.put(t.getId(), t); instances.add(t); }
public TypeList(Type t) { myclass = t.getClass(); instances = new SafeArrayList<Type>(Type.class); hash = new Hashtable<String, Type>(); }