void unload() { this.loaded = false; this.desc = null; for (int i = 0; i < this.stats.length; i++) { this.stats[i].unload(); } this.descriptorMap.clear(); this.descriptorMap = null; }
boolean loadStatDescriptor(StatDescriptor stat, ResourceType type) { // note we don't have instance data yet if (!type.isLoaded()) { return false; } if (filters == null || filters.length == 0) { return true; } else { for (int i = 0; i < filters.length; i++) { if (filters[i].statMatches(stat.getName()) && filters[i].typeMatches(type.getName())) { return true; } } stat.unload(); return false; } }