Search in sources :

Example 6 with TraitPoint

use of delta.games.lotro.stats.traitPoints.TraitPoint in project lotro-companion by dmorcellet.

the class TraitPointsRegistryXMLParser method parseRegistry.

private TraitPointsRegistry parseRegistry(Element root) {
    TraitPointsRegistry registry = new TraitPointsRegistry();
    List<Element> pointTags = DOMParsingTools.getChildTagsByName(root, TraitPointsRegistryXMLConstants.TRAIT_POINT_TAG, false);
    for (Element pointTag : pointTags) {
        TraitPoint item = parsePoint(pointTag);
        registry.registerTraitPoint(item);
    }
    return registry;
}
Also used : TraitPoint(delta.games.lotro.stats.traitPoints.TraitPoint) TraitPointsRegistry(delta.games.lotro.stats.traitPoints.TraitPointsRegistry) Element(org.w3c.dom.Element)

Example 7 with TraitPoint

use of delta.games.lotro.stats.traitPoints.TraitPoint in project lotro-tools by dmorcellet.

the class TraitPointsRegistryBuilder method initPoint.

private TraitPoint initPoint(String id, String category, String label, CharacterClass requiredCharacterClass) {
    TraitPoint point = new TraitPoint(id);
    point.setLabel(label);
    point.setCategory(category);
    if (requiredCharacterClass != null) {
        point.addRequiredClass(requiredCharacterClass);
    }
    _registry.registerTraitPoint(point);
    return point;
}
Also used : TraitPoint(delta.games.lotro.stats.traitPoints.TraitPoint)

Aggregations

TraitPoint (delta.games.lotro.stats.traitPoints.TraitPoint)7 CharacterClass (delta.games.lotro.common.CharacterClass)4 TraitPointsRegistry (delta.games.lotro.stats.traitPoints.TraitPointsRegistry)2 TraitPointLabelComparator (delta.games.lotro.stats.traitPoints.comparators.TraitPointLabelComparator)2 TraitPointFilter (delta.games.lotro.stats.traitPoints.TraitPointFilter)1 TraitPointIdComparator (delta.games.lotro.stats.traitPoints.comparators.TraitPointIdComparator)1 ArrayList (java.util.ArrayList)1 Element (org.w3c.dom.Element)1 NamedNodeMap (org.w3c.dom.NamedNodeMap)1 AttributesImpl (org.xml.sax.helpers.AttributesImpl)1