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

Method parseToken

code/src/java/plugin/bonustokens/MoveAdd.java:33–56  ·  view source on GitHub ↗
(LoadContext context, final String token)

Source from the content-addressed store, hash-verified

31 {Load.LIGHT.toString(), Load.MEDIUM.toString(), Load.HEAVY.toString(), Load.OVERLOAD.toString()};
32
33 @Override
34 protected boolean parseToken(LoadContext context, final String token)
35 {
36 for (int i = 0; i < BONUS_TAGS.length; ++i)
37 {
38 if (BONUS_TAGS[i].equals(token))
39 {
40 addBonusInfo(i);
41
42 return true;
43 }
44 }
45
46 if (token.startsWith(Constants.LST_TYPE_EQUAL))
47 {
48 addBonusInfo(token.replace('=', '.'));
49 }
50 else
51 {
52 addBonusInfo(token);
53 }
54
55 return true;
56 }
57
58 @Override
59 protected String unparseToken(final Object obj)

Callers

nothing calls this directly

Calls 3

addBonusInfoMethod · 0.80
equalsMethod · 0.65
replaceMethod · 0.45

Tested by

no test coverage detected