From: <th...@us...> - 2007-07-03 01:50:24
|
Revision: 3295 http://svn.sourceforge.net/pcgen/?rev=3295&view=rev Author: thpr Date: 2007-07-02 18:50:15 -0700 (Mon, 02 Jul 2007) Log Message: ----------- Package movement to maintain CDOM "no cycles" criteria There are two cycles remaining One is allowed (listener/event) The second is the due to storing PObjects with Keys in Enumerations This may be breakable later on, but is just too hard with the 5.x code running around Modified Paths: -------------- branches/cdom/code/src/java/pcgen/cdom/base/CDOMCompoundReference.java branches/cdom/code/src/java/pcgen/cdom/base/Slot.java branches/cdom/code/src/java/pcgen/cdom/choice/CompoundOrChooser.java branches/cdom/code/src/java/pcgen/cdom/choice/ReferenceChooser.java branches/cdom/code/src/java/pcgen/cdom/content/HitDieCommandFactory.java branches/cdom/code/src/java/pcgen/cdom/content/Remover.java branches/cdom/code/src/java/pcgen/cdom/filter/ReferenceFilter.java branches/cdom/code/src/java/pcgen/cdom/inst/SimpleAssociatedObject.java branches/cdom/code/src/java/pcgen/cdom/modifier/ChangeArmorType.java branches/cdom/code/src/java/pcgen/cdom/modifier/ChangeProf.java branches/cdom/code/src/java/pcgen/cdom/modifier/HitDieFormula.java branches/cdom/code/src/java/pcgen/cdom/modifier/HitDieLock.java branches/cdom/code/src/java/pcgen/cdom/modifier/HitDieStep.java branches/cdom/code/src/java/pcgen/cdom/modifier/MovementFormulaMod.java branches/cdom/code/src/java/pcgen/cdom/modifier/MovementLock.java branches/cdom/code/src/java/pcgen/cdom/modifier/WeightLock.java branches/cdom/code/src/java/pcgen/core/PlayerCharacter.java branches/cdom/code/src/java/pcgen/core/prereq/PreEquippedTester.java branches/cdom/code/src/java/plugin/lsttokens/CcskillLst.java branches/cdom/code/src/java/plugin/lsttokens/CompanionListLst.java branches/cdom/code/src/java/plugin/lsttokens/CskillLst.java branches/cdom/code/src/java/plugin/lsttokens/LangautoLst.java branches/cdom/code/src/java/plugin/lsttokens/MoveLst.java branches/cdom/code/src/java/plugin/lsttokens/QualifyToken.java branches/cdom/code/src/java/plugin/lsttokens/SpelllevelLst.java branches/cdom/code/src/java/plugin/lsttokens/TemplateLst.java branches/cdom/code/src/java/plugin/lsttokens/VFeatLst.java branches/cdom/code/src/java/plugin/lsttokens/VisionLst.java branches/cdom/code/src/java/plugin/lsttokens/auto/ArmorProfToken.java branches/cdom/code/src/java/plugin/lsttokens/auto/ShieldProfToken.java branches/cdom/code/src/java/plugin/lsttokens/auto/WeaponProfToken.java branches/cdom/code/src/java/plugin/lsttokens/deity/DeityweapToken.java branches/cdom/code/src/java/plugin/lsttokens/deity/DomainsToken.java branches/cdom/code/src/java/plugin/lsttokens/domain/FeatToken.java branches/cdom/code/src/java/plugin/lsttokens/equipmentmodifier/ReplacesToken.java branches/cdom/code/src/java/plugin/lsttokens/pcclass/DeityToken.java branches/cdom/code/src/java/plugin/lsttokens/pcclass/FeatautoToken.java branches/cdom/code/src/java/plugin/lsttokens/pcclass/HitdieLst.java branches/cdom/code/src/java/plugin/lsttokens/pcclass/LangbonusToken.java branches/cdom/code/src/java/plugin/lsttokens/pcclass/VfeatToken.java branches/cdom/code/src/java/plugin/lsttokens/pcclass/WeaponbonusToken.java branches/cdom/code/src/java/plugin/lsttokens/race/FavclassToken.java branches/cdom/code/src/java/plugin/lsttokens/race/FeatToken.java branches/cdom/code/src/java/plugin/lsttokens/race/HitdieToken.java branches/cdom/code/src/java/plugin/lsttokens/race/LangbonusToken.java branches/cdom/code/src/java/plugin/lsttokens/race/MonccskillToken.java branches/cdom/code/src/java/plugin/lsttokens/race/MoncskillToken.java branches/cdom/code/src/java/plugin/lsttokens/race/WeaponbonusToken.java branches/cdom/code/src/java/plugin/lsttokens/template/FavoredclassToken.java branches/cdom/code/src/java/plugin/lsttokens/template/FeatToken.java branches/cdom/code/src/java/plugin/lsttokens/template/HitdieToken.java branches/cdom/code/src/java/plugin/lsttokens/template/LangbonusToken.java branches/cdom/code/src/java/plugin/lsttokens/template/WeaponbonusToken.java branches/cdom/code/src/java/plugin/pretokens/test/PreArmorTypeTester.java branches/cdom/code/src/java/plugin/pretokens/test/PreEquipTester.java Added Paths: ----------- branches/cdom/code/src/java/pcgen/cdom/base/AssociationSupport.java branches/cdom/code/src/java/pcgen/cdom/base/ReferenceUtilities.java branches/cdom/code/src/java/pcgen/cdom/character/ branches/cdom/code/src/java/pcgen/cdom/character/EquipmentSetFacade.java branches/cdom/code/src/java/pcgen/cdom/content/AbstractHitDieModifier.java branches/cdom/code/src/java/pcgen/cdom/content/Modifier.java Removed Paths: ------------- branches/cdom/code/src/java/pcgen/cdom/available/SpellProhibitor.java branches/cdom/code/src/java/pcgen/cdom/helper/AssociationSupport.java branches/cdom/code/src/java/pcgen/cdom/helper/EquipmentSetFacade.java branches/cdom/code/src/java/pcgen/cdom/modifier/AbstractHitDieModifier.java branches/cdom/code/src/java/pcgen/cdom/modifier/Modifier.java branches/cdom/code/src/java/pcgen/cdom/util/ReferenceUtilities.java Deleted: branches/cdom/code/src/java/pcgen/cdom/available/SpellProhibitor.java =================================================================== --- branches/cdom/code/src/java/pcgen/cdom/available/SpellProhibitor.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/pcgen/cdom/available/SpellProhibitor.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -1,118 +0,0 @@ -/* - * SpellProhibitor.java Copyright 2005 (c) Stefan Raderamcher - * <rad...@ne...> - * - * This library is free software; you can redistribute it and/or modify it under - * the terms of the GNU Lesser General Public License as published by the Free - * Software Foundation; either version 2.1 of the License, or (at your option) - * any later version. - * - * This library is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS - * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more - * details. - * - * You should have received a copy of the GNU Lesser General Public License - * along with this library; if not, write to the Free Software Foundation, Inc., - * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * Created on March 3, 2005, 16:30 AM - * - * Current Ver: $Revision: 1522 $ Last Editor: $Author: thpr $ Last Edited: - * $Date: 2006-10-24 18:40:09 -0400 (Tue, 24 Oct 2006) $ - * - */ -package pcgen.cdom.available; - -import java.util.ArrayList; -import java.util.List; - -import pcgen.base.enumeration.TypeSafeConstant; -import pcgen.cdom.base.ConcretePrereqObject; -import pcgen.cdom.enumeration.ProhibitedSpellType; -import pcgen.core.Globals; -import pcgen.core.PlayerCharacter; -import pcgen.core.RuleConstants; -import pcgen.core.prereq.PrereqHandler; -import pcgen.core.prereq.Prerequisite; -import pcgen.core.spell.Spell; - -/** - * @author stefan - * - * TODO To change the template for this generated type comment go to Window - - * Preferences - Java - Code Style - Code Templates - */ -public class SpellProhibitor<T extends TypeSafeConstant> extends - ConcretePrereqObject -{ - - private ProhibitedSpellType<T> type = null; - - private List<T> valueList = null; - - public SpellProhibitor() - { - super(); - } - - public ProhibitedSpellType<T> getType() - { - return type; - } - - public List<T> getValueList() - { - return valueList; - } - - public void setType(ProhibitedSpellType<T> prohibitedType) - { - type = prohibitedType; - } - - public void addValue(T value) - { - if (valueList == null) - { - valueList = new ArrayList<T>(); - } - valueList.add(value); - } - - public boolean isProhibited(Spell s, PlayerCharacter aPC) - { - /* - * Note the rule is only "Prohibit Cleric/Druid spells based on - * Alignment" - thus this Globals check is only relevant to the - * Alignment type - */ - if (type.equals(ProhibitedSpellType.ALIGNMENT) - && !Globals.checkRule(RuleConstants.PROHIBITSPELLS)) - { - return false; - } - - List<Prerequisite> prereqList = getPrerequisiteList(); - if (prereqList != null - && !PrereqHandler.passesAll(prereqList, aPC, null)) - { - return false; - } - - int hits = 0; - - for (T typeDesc : type.getCheckList(s)) - { - for (T prohib : valueList) - { - if (prohib.equals(typeDesc)) - { - hits++; - } - } - } - - return hits == valueList.size(); - } -} Copied: branches/cdom/code/src/java/pcgen/cdom/base/AssociationSupport.java (from rev 3223, branches/cdom/code/src/java/pcgen/cdom/helper/AssociationSupport.java) =================================================================== --- branches/cdom/code/src/java/pcgen/cdom/base/AssociationSupport.java (rev 0) +++ branches/cdom/code/src/java/pcgen/cdom/base/AssociationSupport.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -0,0 +1,55 @@ +/* + * Copyright 2007 (C) Tom Parker <th...@us...> + * + * This library is free software; you can redistribute it and/or modify it under + * the terms of the GNU Lesser General Public License as published by the Free + * Software Foundation; either version 2.1 of the License, or (at your option) + * any later version. + * + * This library is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS + * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more + * details. + * + * You should have received a copy of the GNU Lesser General Public License + * along with this library; if not, write to the Free Software Foundation, Inc., + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ +package pcgen.cdom.base; + +import java.util.Collection; +import java.util.HashMap; +import java.util.HashSet; +import java.util.Map; + +import pcgen.cdom.enumeration.AssociationKey; + +public class AssociationSupport implements AssociatedObject +{ + private Map<AssociationKey<?>, Object> associationMap; + + public <T> void setAssociation(AssociationKey<T> name, T value) + { + if (associationMap == null) + { + associationMap = new HashMap<AssociationKey<?>, Object>(); + } + associationMap.put(name, value); + } + + public <T> T getAssociation(AssociationKey<T> name) + { + return (T) (associationMap == null ? null : associationMap.get(name)); + } + + public Collection<AssociationKey<?>> getAssociationKeys() + { + return new HashSet<AssociationKey<?>>(associationMap.keySet()); + } + + public boolean hasAssociations() + { + return associationMap != null && !associationMap.isEmpty(); + } + +} Modified: branches/cdom/code/src/java/pcgen/cdom/base/CDOMCompoundReference.java =================================================================== --- branches/cdom/code/src/java/pcgen/cdom/base/CDOMCompoundReference.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/pcgen/cdom/base/CDOMCompoundReference.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -22,8 +22,6 @@ import java.util.HashSet; import java.util.Set; -import pcgen.cdom.util.ReferenceUtilities; - public class CDOMCompoundReference<T extends PrereqObject> extends CDOMGroupRef<T> { Copied: branches/cdom/code/src/java/pcgen/cdom/base/ReferenceUtilities.java (from rev 3223, branches/cdom/code/src/java/pcgen/cdom/util/ReferenceUtilities.java) =================================================================== --- branches/cdom/code/src/java/pcgen/cdom/base/ReferenceUtilities.java (rev 0) +++ branches/cdom/code/src/java/pcgen/cdom/base/ReferenceUtilities.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -0,0 +1,56 @@ +/* + * Copyright 2007 (C) Tom Parker <th...@us...> + * + * This library is free software; you can redistribute it and/or modify it under + * the terms of the GNU Lesser General Public License as published by the Free + * Software Foundation; either version 2.1 of the License, or (at your option) + * any later version. + * + * This library is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS + * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more + * details. + * + * You should have received a copy of the GNU Lesser General Public License + * along with this library; if not, write to the Free Software Foundation, Inc., + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ +package pcgen.cdom.base; + +import java.util.Collection; + + +public final class ReferenceUtilities +{ + + private ReferenceUtilities() + { + // Cannot construct utility class + } + + public static <T extends LSTWriteable> String joinLstFormat( + Collection<T> set, String separator) + { + if (set == null) + { + return ""; + } + + final StringBuilder result = new StringBuilder(set.size() * 10); + + boolean needjoin = false; + + for (LSTWriteable obj : set) + { + if (needjoin) + { + result.append(separator); + } + needjoin = true; + result.append(obj.getLSTformat()); + } + + return result.toString(); + } + +} Modified: branches/cdom/code/src/java/pcgen/cdom/base/Slot.java =================================================================== --- branches/cdom/code/src/java/pcgen/cdom/base/Slot.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/pcgen/cdom/base/Slot.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -21,7 +21,6 @@ import pcgen.base.formula.Formula; import pcgen.cdom.enumeration.AssociationKey; -import pcgen.cdom.helper.AssociationSupport; public class Slot<T extends PrereqObject> extends ConcretePrereqObject implements LSTWriteable Copied: branches/cdom/code/src/java/pcgen/cdom/character/EquipmentSetFacade.java (from rev 3223, branches/cdom/code/src/java/pcgen/cdom/helper/EquipmentSetFacade.java) =================================================================== --- branches/cdom/code/src/java/pcgen/cdom/character/EquipmentSetFacade.java (rev 0) +++ branches/cdom/code/src/java/pcgen/cdom/character/EquipmentSetFacade.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -0,0 +1,92 @@ +package pcgen.cdom.character; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.List; + +import pcgen.base.graph.visitor.DirectedBreadthFirstTraverseAlgorithm; +import pcgen.cdom.base.PrereqObject; +import pcgen.cdom.content.EquipmentSet; +import pcgen.cdom.enumeration.AssociationKey; +import pcgen.cdom.graph.PCGenGraph; +import pcgen.cdom.graph.PCGraphEdge; +import pcgen.core.Equipment; + +public class EquipmentSetFacade +{ + + private final Class<Equipment> EQUIPMENT_CLASS = Equipment.class; + + private final PCGenGraph graph; + + private final EquipmentSet set; + + public EquipmentSetFacade(PCGenGraph pcgg, EquipmentSet activeSet) + { + if (pcgg == null) + { + throw new IllegalArgumentException("Graph cannot be null"); + } + if (activeSet == null) + { + throw new IllegalArgumentException( + "Active EquipmentSet cannot be null"); + } + graph = pcgg; + set = activeSet; + } + + public Collection<Equipment> getEquipment() + { + DirectedBreadthFirstTraverseAlgorithm<PrereqObject, PCGraphEdge> trav = + new DirectedBreadthFirstTraverseAlgorithm<PrereqObject, PCGraphEdge>( + graph); + trav.traverseFromNode(set); + List<Equipment> list = new ArrayList<Equipment>(); + for (PrereqObject po : trav.getVisitedNodes()) + { + if (EQUIPMENT_CLASS.isInstance(po)) + { + list.add(EQUIPMENT_CLASS.cast(po)); + } + } + return list; + } + + public Collection<Equipment> getEquipment(final int location) + { + DirectedBreadthFirstTraverseAlgorithm<PrereqObject, PCGraphEdge> trav = + new DirectedBreadthFirstTraverseAlgorithm<PrereqObject, PCGraphEdge>( + graph) + { + + @Override + protected boolean canTraverseEdge(PCGraphEdge edge, + PrereqObject gn, int type) + { + if (super.canTraverseEdge(edge, gn, type)) + { + Integer loc = + edge + .getAssociation(AssociationKey.EQUIPMENT_LOCATION); + if (loc != null) + { + return loc.intValue() == location; + } + } + return false; + } + + }; + trav.traverseFromNode(set); + List<Equipment> list = new ArrayList<Equipment>(); + for (PrereqObject po : trav.getVisitedNodes()) + { + if (EQUIPMENT_CLASS.isInstance(po)) + { + list.add(EQUIPMENT_CLASS.cast(po)); + } + } + return list; + } +} Modified: branches/cdom/code/src/java/pcgen/cdom/choice/CompoundOrChooser.java =================================================================== --- branches/cdom/code/src/java/pcgen/cdom/choice/CompoundOrChooser.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/pcgen/cdom/choice/CompoundOrChooser.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -29,8 +29,8 @@ import pcgen.base.lang.StringUtil; import pcgen.cdom.base.Constants; import pcgen.cdom.base.PrereqObject; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.cdom.helper.ChoiceSet; -import pcgen.cdom.util.ReferenceUtilities; import pcgen.core.PlayerCharacter; public class CompoundOrChooser<T extends PrereqObject> extends Modified: branches/cdom/code/src/java/pcgen/cdom/choice/ReferenceChooser.java =================================================================== --- branches/cdom/code/src/java/pcgen/cdom/choice/ReferenceChooser.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/pcgen/cdom/choice/ReferenceChooser.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -31,7 +31,7 @@ import pcgen.cdom.base.CDOMReference; import pcgen.cdom.base.Constants; import pcgen.cdom.base.PrereqObject; -import pcgen.cdom.util.ReferenceUtilities; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.core.PlayerCharacter; import pcgen.persistence.lst.utils.TokenUtilities; Added: branches/cdom/code/src/java/pcgen/cdom/content/AbstractHitDieModifier.java =================================================================== --- branches/cdom/code/src/java/pcgen/cdom/content/AbstractHitDieModifier.java (rev 0) +++ branches/cdom/code/src/java/pcgen/cdom/content/AbstractHitDieModifier.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -0,0 +1,35 @@ +/* + * Copyright 2007 (C) Tom Parker <th...@us...> + * + * This library is free software; you can redistribute it and/or modify it under + * the terms of the GNU Lesser General Public License as published by the Free + * Software Foundation; either version 2.1 of the License, or (at your option) + * any later version. + * + * This library is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS + * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more + * details. + * + * You should have received a copy of the GNU Lesser General Public License + * along with this library; if not, write to the Free Software Foundation, Inc., + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ +package pcgen.cdom.content; + +import pcgen.cdom.base.ConcretePrereqObject; + +public abstract class AbstractHitDieModifier extends ConcretePrereqObject + implements Modifier<HitDie> +{ + + public abstract HitDie applyModifier(HitDie hd); + + public Class<HitDie> getModifiedClass() + { + return HitDie.class; + } + + public abstract String getLSTform(); + +} Modified: branches/cdom/code/src/java/pcgen/cdom/content/HitDieCommandFactory.java =================================================================== --- branches/cdom/code/src/java/pcgen/cdom/content/HitDieCommandFactory.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/pcgen/cdom/content/HitDieCommandFactory.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -19,7 +19,6 @@ import pcgen.cdom.base.ConcretePrereqObject; import pcgen.cdom.base.LSTWriteable; -import pcgen.cdom.modifier.AbstractHitDieModifier; import pcgen.persistence.lst.utils.TokenUtilities; public class HitDieCommandFactory extends ConcretePrereqObject implements Added: branches/cdom/code/src/java/pcgen/cdom/content/Modifier.java =================================================================== --- branches/cdom/code/src/java/pcgen/cdom/content/Modifier.java (rev 0) +++ branches/cdom/code/src/java/pcgen/cdom/content/Modifier.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -0,0 +1,27 @@ +/* + * Copyright 2007 (C) Tom Parker <th...@us...> + * + * This library is free software; you can redistribute it and/or modify it under + * the terms of the GNU Lesser General Public License as published by the Free + * Software Foundation; either version 2.1 of the License, or (at your option) + * any later version. + * + * This library is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS + * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more + * details. + * + * You should have received a copy of the GNU Lesser General Public License + * along with this library; if not, write to the Free Software Foundation, Inc., + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ +package pcgen.cdom.content; + +public interface Modifier<T> +{ + + public T applyModifier(T obj); + + public Class<T> getModifiedClass(); + +} Modified: branches/cdom/code/src/java/pcgen/cdom/content/Remover.java =================================================================== --- branches/cdom/code/src/java/pcgen/cdom/content/Remover.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/pcgen/cdom/content/Remover.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -3,13 +3,13 @@ import java.util.Collection; import pcgen.base.formula.Formula; +import pcgen.cdom.base.AssociationSupport; import pcgen.cdom.base.ConcretePrereqObject; import pcgen.cdom.base.FormulaFactory; import pcgen.cdom.base.LSTWriteable; import pcgen.cdom.base.PrereqObject; import pcgen.cdom.base.Restriction; import pcgen.cdom.enumeration.AssociationKey; -import pcgen.cdom.helper.AssociationSupport; public class Remover<T extends PrereqObject> extends ConcretePrereqObject implements LSTWriteable Modified: branches/cdom/code/src/java/pcgen/cdom/filter/ReferenceFilter.java =================================================================== --- branches/cdom/code/src/java/pcgen/cdom/filter/ReferenceFilter.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/pcgen/cdom/filter/ReferenceFilter.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -27,8 +27,8 @@ import java.util.TreeSet; import pcgen.cdom.base.Constants; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.cdom.helper.ChoiceFilter; -import pcgen.cdom.util.ReferenceUtilities; import pcgen.core.PObject; import pcgen.core.PlayerCharacter; import pcgen.persistence.lst.utils.TokenUtilities; Deleted: branches/cdom/code/src/java/pcgen/cdom/helper/AssociationSupport.java =================================================================== --- branches/cdom/code/src/java/pcgen/cdom/helper/AssociationSupport.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/pcgen/cdom/helper/AssociationSupport.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -1,56 +0,0 @@ -/* - * Copyright 2007 (C) Tom Parker <th...@us...> - * - * This library is free software; you can redistribute it and/or modify it under - * the terms of the GNU Lesser General Public License as published by the Free - * Software Foundation; either version 2.1 of the License, or (at your option) - * any later version. - * - * This library is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS - * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more - * details. - * - * You should have received a copy of the GNU Lesser General Public License - * along with this library; if not, write to the Free Software Foundation, Inc., - * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - */ -package pcgen.cdom.helper; - -import java.util.Collection; -import java.util.HashMap; -import java.util.HashSet; -import java.util.Map; - -import pcgen.cdom.base.AssociatedObject; -import pcgen.cdom.enumeration.AssociationKey; - -public class AssociationSupport implements AssociatedObject -{ - private Map<AssociationKey<?>, Object> associationMap; - - public <T> void setAssociation(AssociationKey<T> name, T value) - { - if (associationMap == null) - { - associationMap = new HashMap<AssociationKey<?>, Object>(); - } - associationMap.put(name, value); - } - - public <T> T getAssociation(AssociationKey<T> name) - { - return (T) (associationMap == null ? null : associationMap.get(name)); - } - - public Collection<AssociationKey<?>> getAssociationKeys() - { - return new HashSet<AssociationKey<?>>(associationMap.keySet()); - } - - public boolean hasAssociations() - { - return associationMap != null && !associationMap.isEmpty(); - } - -} Deleted: branches/cdom/code/src/java/pcgen/cdom/helper/EquipmentSetFacade.java =================================================================== --- branches/cdom/code/src/java/pcgen/cdom/helper/EquipmentSetFacade.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/pcgen/cdom/helper/EquipmentSetFacade.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -1,92 +0,0 @@ -package pcgen.cdom.helper; - -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; - -import pcgen.base.graph.visitor.DirectedBreadthFirstTraverseAlgorithm; -import pcgen.cdom.base.PrereqObject; -import pcgen.cdom.content.EquipmentSet; -import pcgen.cdom.enumeration.AssociationKey; -import pcgen.cdom.graph.PCGenGraph; -import pcgen.cdom.graph.PCGraphEdge; -import pcgen.core.Equipment; - -public class EquipmentSetFacade -{ - - private final Class<Equipment> EQUIPMENT_CLASS = Equipment.class; - - private final PCGenGraph graph; - - private final EquipmentSet set; - - public EquipmentSetFacade(PCGenGraph pcgg, EquipmentSet activeSet) - { - if (pcgg == null) - { - throw new IllegalArgumentException("Graph cannot be null"); - } - if (activeSet == null) - { - throw new IllegalArgumentException( - "Active EquipmentSet cannot be null"); - } - graph = pcgg; - set = activeSet; - } - - public Collection<Equipment> getEquipment() - { - DirectedBreadthFirstTraverseAlgorithm<PrereqObject, PCGraphEdge> trav = - new DirectedBreadthFirstTraverseAlgorithm<PrereqObject, PCGraphEdge>( - graph); - trav.traverseFromNode(set); - List<Equipment> list = new ArrayList<Equipment>(); - for (PrereqObject po : trav.getVisitedNodes()) - { - if (EQUIPMENT_CLASS.isInstance(po)) - { - list.add(EQUIPMENT_CLASS.cast(po)); - } - } - return list; - } - - public Collection<Equipment> getEquipment(final int location) - { - DirectedBreadthFirstTraverseAlgorithm<PrereqObject, PCGraphEdge> trav = - new DirectedBreadthFirstTraverseAlgorithm<PrereqObject, PCGraphEdge>( - graph) - { - - @Override - protected boolean canTraverseEdge(PCGraphEdge edge, - PrereqObject gn, int type) - { - if (super.canTraverseEdge(edge, gn, type)) - { - Integer loc = - edge - .getAssociation(AssociationKey.EQUIPMENT_LOCATION); - if (loc != null) - { - return loc.intValue() == location; - } - } - return false; - } - - }; - trav.traverseFromNode(set); - List<Equipment> list = new ArrayList<Equipment>(); - for (PrereqObject po : trav.getVisitedNodes()) - { - if (EQUIPMENT_CLASS.isInstance(po)) - { - list.add(EQUIPMENT_CLASS.cast(po)); - } - } - return list; - } -} Modified: branches/cdom/code/src/java/pcgen/cdom/inst/SimpleAssociatedObject.java =================================================================== --- branches/cdom/code/src/java/pcgen/cdom/inst/SimpleAssociatedObject.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/pcgen/cdom/inst/SimpleAssociatedObject.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -3,9 +3,9 @@ import java.util.Collection; import pcgen.cdom.base.AssociatedPrereqObject; +import pcgen.cdom.base.AssociationSupport; import pcgen.cdom.base.ConcretePrereqObject; import pcgen.cdom.enumeration.AssociationKey; -import pcgen.cdom.helper.AssociationSupport; public class SimpleAssociatedObject extends ConcretePrereqObject implements AssociatedPrereqObject Deleted: branches/cdom/code/src/java/pcgen/cdom/modifier/AbstractHitDieModifier.java =================================================================== --- branches/cdom/code/src/java/pcgen/cdom/modifier/AbstractHitDieModifier.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/pcgen/cdom/modifier/AbstractHitDieModifier.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -1,36 +0,0 @@ -/* - * Copyright 2007 (C) Tom Parker <th...@us...> - * - * This library is free software; you can redistribute it and/or modify it under - * the terms of the GNU Lesser General Public License as published by the Free - * Software Foundation; either version 2.1 of the License, or (at your option) - * any later version. - * - * This library is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS - * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more - * details. - * - * You should have received a copy of the GNU Lesser General Public License - * along with this library; if not, write to the Free Software Foundation, Inc., - * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - */ -package pcgen.cdom.modifier; - -import pcgen.cdom.base.ConcretePrereqObject; -import pcgen.cdom.content.HitDie; - -public abstract class AbstractHitDieModifier extends ConcretePrereqObject - implements Modifier<HitDie> -{ - - public abstract HitDie applyModifier(HitDie hd); - - public Class<HitDie> getModifiedClass() - { - return HitDie.class; - } - - public abstract String getLSTform(); - -} Modified: branches/cdom/code/src/java/pcgen/cdom/modifier/ChangeArmorType.java =================================================================== --- branches/cdom/code/src/java/pcgen/cdom/modifier/ChangeArmorType.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/pcgen/cdom/modifier/ChangeArmorType.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -19,6 +19,7 @@ import pcgen.cdom.base.ConcretePrereqObject; import pcgen.cdom.base.LSTWriteable; +import pcgen.cdom.content.Modifier; import pcgen.cdom.enumeration.Type; public class ChangeArmorType extends ConcretePrereqObject implements Modified: branches/cdom/code/src/java/pcgen/cdom/modifier/ChangeProf.java =================================================================== --- branches/cdom/code/src/java/pcgen/cdom/modifier/ChangeProf.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/pcgen/cdom/modifier/ChangeProf.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -21,6 +21,7 @@ import pcgen.cdom.base.CDOMReference; import pcgen.cdom.base.ConcretePrereqObject; import pcgen.cdom.base.LSTWriteable; +import pcgen.cdom.content.Modifier; import pcgen.core.WeaponProf; public class ChangeProf extends ConcretePrereqObject implements Modified: branches/cdom/code/src/java/pcgen/cdom/modifier/HitDieFormula.java =================================================================== --- branches/cdom/code/src/java/pcgen/cdom/modifier/HitDieFormula.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/pcgen/cdom/modifier/HitDieFormula.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -18,6 +18,7 @@ package pcgen.cdom.modifier; import pcgen.base.formula.ReferenceFormula; +import pcgen.cdom.content.AbstractHitDieModifier; import pcgen.cdom.content.HitDie; public class HitDieFormula extends AbstractHitDieModifier Modified: branches/cdom/code/src/java/pcgen/cdom/modifier/HitDieLock.java =================================================================== --- branches/cdom/code/src/java/pcgen/cdom/modifier/HitDieLock.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/pcgen/cdom/modifier/HitDieLock.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -17,6 +17,7 @@ */ package pcgen.cdom.modifier; +import pcgen.cdom.content.AbstractHitDieModifier; import pcgen.cdom.content.HitDie; public class HitDieLock extends AbstractHitDieModifier Modified: branches/cdom/code/src/java/pcgen/cdom/modifier/HitDieStep.java =================================================================== --- branches/cdom/code/src/java/pcgen/cdom/modifier/HitDieStep.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/pcgen/cdom/modifier/HitDieStep.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -17,6 +17,7 @@ */ package pcgen.cdom.modifier; +import pcgen.cdom.content.AbstractHitDieModifier; import pcgen.cdom.content.HitDie; public class HitDieStep extends AbstractHitDieModifier Deleted: branches/cdom/code/src/java/pcgen/cdom/modifier/Modifier.java =================================================================== --- branches/cdom/code/src/java/pcgen/cdom/modifier/Modifier.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/pcgen/cdom/modifier/Modifier.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -1,27 +0,0 @@ -/* - * Copyright 2007 (C) Tom Parker <th...@us...> - * - * This library is free software; you can redistribute it and/or modify it under - * the terms of the GNU Lesser General Public License as published by the Free - * Software Foundation; either version 2.1 of the License, or (at your option) - * any later version. - * - * This library is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS - * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more - * details. - * - * You should have received a copy of the GNU Lesser General Public License - * along with this library; if not, write to the Free Software Foundation, Inc., - * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - */ -package pcgen.cdom.modifier; - -public interface Modifier<T> -{ - - public T applyModifier(T obj); - - public Class<T> getModifiedClass(); - -} Modified: branches/cdom/code/src/java/pcgen/cdom/modifier/MovementFormulaMod.java =================================================================== --- branches/cdom/code/src/java/pcgen/cdom/modifier/MovementFormulaMod.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/pcgen/cdom/modifier/MovementFormulaMod.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -21,6 +21,7 @@ import pcgen.base.formula.ReferenceFormula; import pcgen.cdom.base.ConcretePrereqObject; +import pcgen.cdom.content.Modifier; import pcgen.cdom.content.SimpleMovement; public class MovementFormulaMod extends ConcretePrereqObject implements Modified: branches/cdom/code/src/java/pcgen/cdom/modifier/MovementLock.java =================================================================== --- branches/cdom/code/src/java/pcgen/cdom/modifier/MovementLock.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/pcgen/cdom/modifier/MovementLock.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -18,6 +18,7 @@ package pcgen.cdom.modifier; import pcgen.cdom.base.ConcretePrereqObject; +import pcgen.cdom.content.Modifier; import pcgen.cdom.content.SimpleMovement; public class MovementLock extends ConcretePrereqObject implements Modified: branches/cdom/code/src/java/pcgen/cdom/modifier/WeightLock.java =================================================================== --- branches/cdom/code/src/java/pcgen/cdom/modifier/WeightLock.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/pcgen/cdom/modifier/WeightLock.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -17,6 +17,7 @@ */ package pcgen.cdom.modifier; +import pcgen.cdom.content.Modifier; import pcgen.cdom.content.Weight; public class WeightLock implements Modifier<Weight> Deleted: branches/cdom/code/src/java/pcgen/cdom/util/ReferenceUtilities.java =================================================================== --- branches/cdom/code/src/java/pcgen/cdom/util/ReferenceUtilities.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/pcgen/cdom/util/ReferenceUtilities.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -1,57 +0,0 @@ -/* - * Copyright 2007 (C) Tom Parker <th...@us...> - * - * This library is free software; you can redistribute it and/or modify it under - * the terms of the GNU Lesser General Public License as published by the Free - * Software Foundation; either version 2.1 of the License, or (at your option) - * any later version. - * - * This library is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS - * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more - * details. - * - * You should have received a copy of the GNU Lesser General Public License - * along with this library; if not, write to the Free Software Foundation, Inc., - * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - */ -package pcgen.cdom.util; - -import java.util.Collection; - -import pcgen.cdom.base.LSTWriteable; - -public final class ReferenceUtilities -{ - - private ReferenceUtilities() - { - // Cannot construct utility class - } - - public static <T extends LSTWriteable> String joinLstFormat( - Collection<T> set, String separator) - { - if (set == null) - { - return ""; - } - - final StringBuilder result = new StringBuilder(set.size() * 10); - - boolean needjoin = false; - - for (LSTWriteable obj : set) - { - if (needjoin) - { - result.append(separator); - } - needjoin = true; - result.append(obj.getLSTformat()); - } - - return result.toString(); - } - -} Modified: branches/cdom/code/src/java/pcgen/core/PlayerCharacter.java =================================================================== --- branches/cdom/code/src/java/pcgen/core/PlayerCharacter.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/pcgen/core/PlayerCharacter.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -60,6 +60,7 @@ import pcgen.cdom.base.CDOMList; import pcgen.cdom.base.CDOMObject; import pcgen.cdom.base.PrereqObject; +import pcgen.cdom.character.EquipmentSetFacade; import pcgen.cdom.content.EquipmentSet; import pcgen.cdom.content.SimpleMovement; import pcgen.cdom.content.SpellResistance; @@ -71,7 +72,6 @@ import pcgen.cdom.enumeration.StringKey; import pcgen.cdom.graph.PCGenGraph; import pcgen.cdom.graph.PCGraphEdge; -import pcgen.cdom.helper.EquipmentSetFacade; import pcgen.cdom.inst.PCClassLevel; import pcgen.cdom.lists.PCGenLists; import pcgen.cdom.mode.Size; Modified: branches/cdom/code/src/java/pcgen/core/prereq/PreEquippedTester.java =================================================================== --- branches/cdom/code/src/java/pcgen/core/prereq/PreEquippedTester.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/pcgen/core/prereq/PreEquippedTester.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -28,9 +28,9 @@ import java.util.StringTokenizer; +import pcgen.cdom.character.EquipmentSetFacade; import pcgen.cdom.enumeration.ListKey; import pcgen.cdom.enumeration.Type; -import pcgen.cdom.helper.EquipmentSetFacade; import pcgen.core.Equipment; import pcgen.core.PlayerCharacter; import pcgen.core.character.WieldCategory; Modified: branches/cdom/code/src/java/plugin/lsttokens/CcskillLst.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/CcskillLst.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/CcskillLst.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -33,9 +33,9 @@ import pcgen.cdom.base.CDOMReference; import pcgen.cdom.base.Constants; import pcgen.cdom.base.LSTWriteable; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.cdom.enumeration.AssociationKey; import pcgen.cdom.enumeration.SkillCost; -import pcgen.cdom.util.ReferenceUtilities; import pcgen.core.ClassSkillList; import pcgen.core.PObject; import pcgen.core.Skill; Modified: branches/cdom/code/src/java/plugin/lsttokens/CompanionListLst.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/CompanionListLst.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/CompanionListLst.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -40,8 +40,8 @@ import pcgen.cdom.base.CDOMReference; import pcgen.cdom.base.Constants; import pcgen.cdom.base.LSTWriteable; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.cdom.enumeration.AssociationKey; -import pcgen.cdom.util.ReferenceUtilities; import pcgen.core.CompanionList; import pcgen.core.FollowerOption; import pcgen.core.PObject; Modified: branches/cdom/code/src/java/plugin/lsttokens/CskillLst.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/CskillLst.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/CskillLst.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -33,9 +33,9 @@ import pcgen.cdom.base.CDOMReference; import pcgen.cdom.base.Constants; import pcgen.cdom.base.LSTWriteable; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.cdom.enumeration.AssociationKey; import pcgen.cdom.enumeration.SkillCost; -import pcgen.cdom.util.ReferenceUtilities; import pcgen.core.ClassSkillList; import pcgen.core.PObject; import pcgen.core.Skill; Modified: branches/cdom/code/src/java/plugin/lsttokens/LangautoLst.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/LangautoLst.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/LangautoLst.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -29,7 +29,7 @@ import pcgen.cdom.base.CDOMReference; import pcgen.cdom.base.Constants; import pcgen.cdom.base.LSTWriteable; -import pcgen.cdom.util.ReferenceUtilities; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.core.Language; import pcgen.core.PObject; import pcgen.persistence.GraphChanges; Modified: branches/cdom/code/src/java/plugin/lsttokens/MoveLst.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/MoveLst.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/MoveLst.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -29,8 +29,8 @@ import pcgen.cdom.base.CDOMObject; import pcgen.cdom.base.Constants; import pcgen.cdom.base.LSTWriteable; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.cdom.content.SimpleMovement; -import pcgen.cdom.util.ReferenceUtilities; import pcgen.core.Equipment; import pcgen.core.Movement; import pcgen.core.PObject; Modified: branches/cdom/code/src/java/plugin/lsttokens/QualifyToken.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/QualifyToken.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/QualifyToken.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -32,8 +32,8 @@ import pcgen.cdom.base.CDOMReference; import pcgen.cdom.base.CategorizedCDOMReference; import pcgen.cdom.base.Category; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.cdom.enumeration.MapKey; -import pcgen.cdom.util.ReferenceUtilities; import pcgen.core.Ability; import pcgen.core.Constants; import pcgen.core.Deity; Modified: branches/cdom/code/src/java/plugin/lsttokens/SpelllevelLst.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/SpelllevelLst.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/SpelllevelLst.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -41,8 +41,8 @@ import pcgen.cdom.base.CDOMReference; import pcgen.cdom.base.Constants; import pcgen.cdom.base.LSTWriteable; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.cdom.enumeration.AssociationKey; -import pcgen.cdom.util.ReferenceUtilities; import pcgen.core.Campaign; import pcgen.core.ClassSpellList; import pcgen.core.DomainSpellList; Modified: branches/cdom/code/src/java/plugin/lsttokens/TemplateLst.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/TemplateLst.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/TemplateLst.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -33,7 +33,7 @@ import pcgen.cdom.base.Constants; import pcgen.cdom.base.FormulaFactory; import pcgen.cdom.base.LSTWriteable; -import pcgen.cdom.util.ReferenceUtilities; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.core.Campaign; import pcgen.core.PCTemplate; import pcgen.core.PCTemplateList; Modified: branches/cdom/code/src/java/plugin/lsttokens/VFeatLst.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/VFeatLst.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/VFeatLst.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -16,11 +16,11 @@ import pcgen.cdom.base.CDOMObject; import pcgen.cdom.base.CategorizedCDOMReference; import pcgen.cdom.base.LSTWriteable; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.cdom.enumeration.AbilityCategory; import pcgen.cdom.enumeration.AbilityNature; import pcgen.cdom.enumeration.AssociationKey; import pcgen.cdom.graph.PCGraphGrantsEdge; -import pcgen.cdom.util.ReferenceUtilities; import pcgen.core.Ability; import pcgen.core.Constants; import pcgen.core.PObject; Modified: branches/cdom/code/src/java/plugin/lsttokens/VisionLst.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/VisionLst.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/VisionLst.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -30,7 +30,7 @@ import pcgen.cdom.base.CDOMObject; import pcgen.cdom.base.Constants; import pcgen.cdom.base.LSTWriteable; -import pcgen.cdom.util.ReferenceUtilities; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.core.PCClass; import pcgen.core.PObject; import pcgen.core.Vision; Modified: branches/cdom/code/src/java/plugin/lsttokens/auto/ArmorProfToken.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/auto/ArmorProfToken.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/auto/ArmorProfToken.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -32,8 +32,8 @@ import pcgen.cdom.base.CDOMReference; import pcgen.cdom.base.Constants; import pcgen.cdom.base.LSTWriteable; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.cdom.graph.PCGraphGrantsEdge; -import pcgen.cdom.util.ReferenceUtilities; import pcgen.core.ArmorProf; import pcgen.core.PObject; import pcgen.core.prereq.Prerequisite; Modified: branches/cdom/code/src/java/plugin/lsttokens/auto/ShieldProfToken.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/auto/ShieldProfToken.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/auto/ShieldProfToken.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -32,8 +32,8 @@ import pcgen.cdom.base.CDOMReference; import pcgen.cdom.base.Constants; import pcgen.cdom.base.LSTWriteable; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.cdom.graph.PCGraphGrantsEdge; -import pcgen.cdom.util.ReferenceUtilities; import pcgen.core.PObject; import pcgen.core.ShieldProf; import pcgen.core.prereq.Prerequisite; Modified: branches/cdom/code/src/java/plugin/lsttokens/auto/WeaponProfToken.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/auto/WeaponProfToken.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/auto/WeaponProfToken.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -32,8 +32,8 @@ import pcgen.cdom.base.CDOMReference; import pcgen.cdom.base.Constants; import pcgen.cdom.base.LSTWriteable; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.cdom.graph.PCGraphGrantsEdge; -import pcgen.cdom.util.ReferenceUtilities; import pcgen.core.PObject; import pcgen.core.WeaponProf; import pcgen.core.prereq.Prerequisite; Modified: branches/cdom/code/src/java/plugin/lsttokens/deity/DeityweapToken.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/deity/DeityweapToken.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/deity/DeityweapToken.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -25,8 +25,8 @@ import pcgen.cdom.base.CDOMSimpleSingleRef; import pcgen.cdom.base.Constants; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.cdom.enumeration.ListKey; -import pcgen.cdom.util.ReferenceUtilities; import pcgen.core.Deity; import pcgen.core.WeaponProf; import pcgen.persistence.Changes; Modified: branches/cdom/code/src/java/plugin/lsttokens/deity/DomainsToken.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/deity/DomainsToken.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/deity/DomainsToken.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -35,7 +35,7 @@ import pcgen.cdom.base.AssociatedPrereqObject; import pcgen.cdom.base.CDOMReference; import pcgen.cdom.base.Constants; -import pcgen.cdom.util.ReferenceUtilities; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.core.Deity; import pcgen.core.Domain; import pcgen.core.DomainList; Modified: branches/cdom/code/src/java/plugin/lsttokens/domain/FeatToken.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/domain/FeatToken.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/domain/FeatToken.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -40,11 +40,11 @@ import pcgen.cdom.base.CategorizedCDOMReference; import pcgen.cdom.base.Constants; import pcgen.cdom.base.LSTWriteable; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.cdom.enumeration.AbilityCategory; import pcgen.cdom.enumeration.AbilityNature; import pcgen.cdom.enumeration.AssociationKey; import pcgen.cdom.graph.PCGraphGrantsEdge; -import pcgen.cdom.util.ReferenceUtilities; import pcgen.core.Ability; import pcgen.core.Domain; import pcgen.core.prereq.Prerequisite; Modified: branches/cdom/code/src/java/plugin/lsttokens/equipmentmodifier/ReplacesToken.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/equipmentmodifier/ReplacesToken.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/equipmentmodifier/ReplacesToken.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -25,8 +25,8 @@ import pcgen.cdom.base.CDOMSimpleSingleRef; import pcgen.cdom.base.Constants; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.cdom.enumeration.ListKey; -import pcgen.cdom.util.ReferenceUtilities; import pcgen.core.EquipmentModifier; import pcgen.persistence.Changes; import pcgen.persistence.LoadContext; Modified: branches/cdom/code/src/java/plugin/lsttokens/pcclass/DeityToken.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/pcclass/DeityToken.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/pcclass/DeityToken.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -26,7 +26,7 @@ import pcgen.cdom.base.CDOMReference; import pcgen.cdom.base.LSTWriteable; -import pcgen.cdom.util.ReferenceUtilities; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.core.Constants; import pcgen.core.Deity; import pcgen.core.PCClass; Modified: branches/cdom/code/src/java/plugin/lsttokens/pcclass/FeatautoToken.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/pcclass/FeatautoToken.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/pcclass/FeatautoToken.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -39,11 +39,11 @@ import pcgen.cdom.base.CDOMReference; import pcgen.cdom.base.CategorizedCDOMReference; import pcgen.cdom.base.LSTWriteable; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.cdom.enumeration.AbilityCategory; import pcgen.cdom.enumeration.AbilityNature; import pcgen.cdom.enumeration.AssociationKey; import pcgen.cdom.graph.PCGraphGrantsEdge; -import pcgen.cdom.util.ReferenceUtilities; import pcgen.core.Ability; import pcgen.core.Constants; import pcgen.core.PCClass; Modified: branches/cdom/code/src/java/plugin/lsttokens/pcclass/HitdieLst.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/pcclass/HitdieLst.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/pcclass/HitdieLst.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -27,11 +27,11 @@ import pcgen.base.formula.MultiplyingFormula; import pcgen.base.formula.SubtractingFormula; import pcgen.cdom.base.Constants; +import pcgen.cdom.content.AbstractHitDieModifier; import pcgen.cdom.content.HitDie; import pcgen.cdom.content.HitDieCommandFactory; import pcgen.cdom.enumeration.ObjectKey; import pcgen.cdom.inst.PCClassLevel; -import pcgen.cdom.modifier.AbstractHitDieModifier; import pcgen.cdom.modifier.HitDieFormula; import pcgen.cdom.modifier.HitDieLock; import pcgen.cdom.modifier.HitDieStep; Modified: branches/cdom/code/src/java/plugin/lsttokens/pcclass/LangbonusToken.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/pcclass/LangbonusToken.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/pcclass/LangbonusToken.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -27,7 +27,7 @@ import pcgen.cdom.base.CDOMReference; import pcgen.cdom.base.Constants; -import pcgen.cdom.util.ReferenceUtilities; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.core.Language; import pcgen.core.LanguageList; import pcgen.core.PCClass; Modified: branches/cdom/code/src/java/plugin/lsttokens/pcclass/VfeatToken.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/pcclass/VfeatToken.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/pcclass/VfeatToken.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -40,11 +40,11 @@ import pcgen.cdom.base.CategorizedCDOMReference; import pcgen.cdom.base.Constants; import pcgen.cdom.base.LSTWriteable; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.cdom.enumeration.AbilityCategory; import pcgen.cdom.enumeration.AbilityNature; import pcgen.cdom.enumeration.AssociationKey; import pcgen.cdom.graph.PCGraphGrantsEdge; -import pcgen.cdom.util.ReferenceUtilities; import pcgen.core.Ability; import pcgen.core.PCClass; import pcgen.core.PObject; Modified: branches/cdom/code/src/java/plugin/lsttokens/pcclass/WeaponbonusToken.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/pcclass/WeaponbonusToken.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/pcclass/WeaponbonusToken.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -28,7 +28,7 @@ import pcgen.cdom.base.CDOMObject; import pcgen.cdom.base.CDOMReference; import pcgen.cdom.base.Constants; -import pcgen.cdom.util.ReferenceUtilities; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.core.PCClass; import pcgen.core.WeaponProf; import pcgen.core.WeaponProfList; Modified: branches/cdom/code/src/java/plugin/lsttokens/race/FavclassToken.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/race/FavclassToken.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/race/FavclassToken.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -28,8 +28,8 @@ import pcgen.cdom.base.CDOMObject; import pcgen.cdom.base.CDOMReference; import pcgen.cdom.base.Constants; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.cdom.enumeration.ListKey; -import pcgen.cdom.util.ReferenceUtilities; import pcgen.core.PCClass; import pcgen.core.Race; import pcgen.persistence.Changes; Modified: branches/cdom/code/src/java/plugin/lsttokens/race/FeatToken.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/race/FeatToken.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/race/FeatToken.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -40,11 +40,11 @@ import pcgen.cdom.base.CategorizedCDOMReference; import pcgen.cdom.base.Constants; import pcgen.cdom.base.LSTWriteable; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.cdom.enumeration.AbilityCategory; import pcgen.cdom.enumeration.AbilityNature; import pcgen.cdom.enumeration.AssociationKey; import pcgen.cdom.graph.PCGraphGrantsEdge; -import pcgen.cdom.util.ReferenceUtilities; import pcgen.core.Ability; import pcgen.core.Race; import pcgen.core.prereq.Prerequisite; Modified: branches/cdom/code/src/java/plugin/lsttokens/race/HitdieToken.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/race/HitdieToken.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/race/HitdieToken.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -33,9 +33,9 @@ import pcgen.cdom.base.CDOMReference; import pcgen.cdom.base.Constants; import pcgen.cdom.base.LSTWriteable; +import pcgen.cdom.content.AbstractHitDieModifier; import pcgen.cdom.content.HitDie; import pcgen.cdom.content.HitDieCommandFactory; -import pcgen.cdom.modifier.AbstractHitDieModifier; import pcgen.cdom.modifier.HitDieFormula; import pcgen.cdom.modifier.HitDieLock; import pcgen.cdom.modifier.HitDieStep; Modified: branches/cdom/code/src/java/plugin/lsttokens/race/LangbonusToken.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/race/LangbonusToken.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/race/LangbonusToken.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -27,7 +27,7 @@ import pcgen.cdom.base.CDOMReference; import pcgen.cdom.base.Constants; -import pcgen.cdom.util.ReferenceUtilities; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.core.Language; import pcgen.core.LanguageList; import pcgen.core.Race; Modified: branches/cdom/code/src/java/plugin/lsttokens/race/MonccskillToken.java =================================================================== --- branches/cdom/code/src/java/plugin/lsttokens/race/MonccskillToken.java 2007-07-02 21:05:00 UTC (rev 3294) +++ branches/cdom/code/src/java/plugin/lsttokens/race/MonccskillToken.java 2007-07-03 01:50:15 UTC (rev 3295) @@ -29,9 +29,9 @@ import pcgen.cdom.base.AssociatedPrereqObject; import pcgen.cdom.base.CDOMReference; import pcgen.cdom.base.Constants; +import pcgen.cdom.base.ReferenceUtilities; import pcgen.cdom.enumeration.AssociationKey; import pcgen.cdom.enumeration.SkillCost; -import pcgen.cdom.util.ReferenceUtilities; import pcgen.core.ClassSkillList; import pcgen.core.Race; impor... [truncated message content] |