private void parseBeanSets( Node first, int length, int startLvl, List<ValidatingStatsSet> statsSets, String setName) { for (int i = 0; i < length; i++) { ValidatingStatsSet set = STATS_SET_POOL.getSkillSet(i + startLvl); statsSets.add(set); boolean isEnchant = false; if (startLvl >= 100) { isEnchant = true; for (Node n = first; n != null; n = n.getNextSibling()) { if ("set".equalsIgnoreCase(n.getNodeName())) parseBeanSet(n, set, _sets.size(), false); } } for (Node n = first; n != null; n = n.getNextSibling()) { if (setName.equalsIgnoreCase(n.getNodeName())) parseBeanSet(n, set, i + 1, isEnchant); } } }
private void clear(List<ValidatingStatsSet> statsSets) { for (ValidatingStatsSet set : statsSets) STATS_SET_POOL.store(set); statsSets.clear(); }