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

Method unparse

code/src/java/plugin/lsttokens/ModifyLst.java:186–203  ·  view source on GitHub ↗
(LoadContext context, VarContainer obj)

Source from the content-addressed store, hash-verified

184 }
185
186 @Override
187 public String[] unparse(LoadContext context, VarContainer obj)
188 {
189 List<String> modifiers = new ArrayList<>();
190 for (VarModifier<?> vm : obj.getModifierArray())
191 {
192 String sb = vm.getVarName()
193 + Constants.PIPE
194 + unparseModifier(vm);
195 modifiers.add(sb);
196 }
197 if (modifiers.isEmpty())
198 {
199 //Legal
200 return null;
201 }
202 return modifiers.toArray(new String[0]);
203 }
204
205 /**
206 * Unparses a VarModifier into the string of instructions used to produce it.

Callers

nothing calls this directly

Calls 6

unparseModifierMethod · 0.95
getModifierArrayMethod · 0.65
addMethod · 0.65
isEmptyMethod · 0.65
getVarNameMethod · 0.45
toArrayMethod · 0.45

Tested by

no test coverage detected