コード例 #1
0
 private void setBonusPoints(GenericCharacterTemplate characterTemplate, Element creationElement)
     throws PersistenceException {
   Element bonusPointsElement = creationElement.element("bonusPointCosts");
   if (bonusPointsElement == null) {
     return;
   }
   BonusPointCostTemplateParser parser =
       new BonusPointCostTemplateParser(registryCollection.getBonusPointTemplateRegistry());
   GenericBonusPointCosts bonusPoints = parser.parseTemplate(bonusPointsElement);
   characterTemplate.setBonusPointCosts(bonusPoints);
 }
コード例 #2
0
 private void setExperiencePoints(
     GenericCharacterTemplate characterTemplate, Element experienceElement)
     throws PersistenceException {
   Element experiencePointsElement = experienceElement.element(TAG_EXPERIENCE_POINT_COST);
   if (experiencePointsElement == null) {
     return;
   }
   ExperienceTemplateParser parser =
       new ExperienceTemplateParser(registryCollection.getExperienceTemplateRegistry());
   GenericExperiencePointCosts experienceTemplate = parser.parseTemplate(experiencePointsElement);
   characterTemplate.setExperiencePointCosts(experienceTemplate);
 }
コード例 #3
0
 private CreationPointTemplateParser createCreationPointTemplateParser() {
   return new CreationPointTemplateParser(registryCollection.getCreationPointTemplateRegistry());
 }
コード例 #4
0
 public CharacterTemplateParser(
     CharacterTypes characterTypes, ICharacterTemplateRegistryCollection registryCollection) {
   super(registryCollection.getCharacterTemplateRegistry());
   this.characterTypes = characterTypes;
   this.registryCollection = registryCollection;
 }