java-design-patterns icon indicating copy to clipboard operation
java-design-patterns copied to clipboard

add getAttackPower method to pattern decorator

Open ponyfe opened this issue 11 years ago • 0 comments

Add getAttackPower method to pattern decorator may make it more easily to understand .

when the troll not add smart decorator , his attack power is 10 ,but when we build the smartTroll , his attack power is 10(the normal troll's attack power) + 20(because smart). So ,it's more easy to understand .

ponyfe avatar Sep 10 '15 10:09 ponyfe