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

Method getTempBonuses

code/src/java/pcgen/core/BonusManager.java:996–1015  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

994 }
995
996 private Map<BonusObj, Object> getTempBonuses()
997 {
998 Map<BonusObj, Object> map = new IdentityHashMap<>();
999 getFilteredTempBonusList().forEach((bonus, value) -> {
1000 pc.setApplied(bonus, false);
1001
1002 Object source = value.source;
1003 CDOMObject cdomsource = (source instanceof CDOMObject) ? (CDOMObject) source : null;
1004 if (bonus.qualifies(pc, cdomsource))
1005 {
1006 pc.setApplied(bonus, true);
1007 }
1008
1009 if (pc.isApplied(bonus))
1010 {
1011 map.put(bonus, source);
1012 }
1013 });
1014 return map;
1015 }
1016
1017 public Map<BonusObj, TempBonusInfo> getTempBonusMap(String aCreator, String aTarget)
1018 {

Callers 1

getAllActiveBonusesMethod · 0.95

Calls 6

forEachMethod · 0.80
setAppliedMethod · 0.80
isAppliedMethod · 0.80
qualifiesMethod · 0.65
putMethod · 0.65

Tested by

no test coverage detected