MCPcopy Create free account
hub / github.com/PCGen/pcgen / copyFields

Method copyFields

code/src/java/pcgen/core/AbilityCategory.java:127–150  ·  view source on GitHub ↗

Update this ability category using the values from the supplied ability category. @param srcCat The category to be copied.

(AbilityCategory srcCat)

Source from the content-addressed store, hash-verified

125 * @param srcCat The category to be copied.
126 */
127 public void copyFields(AbilityCategory srcCat)
128 {
129 sourceURI = srcCat.sourceURI;
130 keyName = srcCat.keyName;
131 displayName = srcCat.displayName;
132 pluralName = srcCat.pluralName;
133 if (srcCat.getParentCategory() == srcCat)
134 {
135 parentCategory = CDOMDirectSingleRef.getRef(this);
136 }
137 else
138 {
139 parentCategory = srcCat.parentCategory;
140 }
141 displayLocation = srcCat.displayLocation;
142 isAllAbilityTypes = srcCat.isAllAbilityTypes;
143 types = (srcCat.types == null) ? null : new HashSet<>(srcCat.types);
144 poolFormula = srcCat.poolFormula;
145 visibility = srcCat.visibility;
146 isEditable = srcCat.isEditable;
147 isPoolModifiable = srcCat.isPoolModifiable;
148 isPoolFractional = srcCat.isPoolFractional;
149 isInternal = srcCat.isInternal;
150 }
151
152 /**
153 * Constructor takes a key name and display name for the category.

Callers 2

loadGameModeMiscInfoMethod · 0.95
setGameMethod · 0.80

Calls 2

getRefMethod · 0.95
getParentCategoryMethod · 0.65

Tested by

no test coverage detected