mirror of
https://github.com/tiennm99/java-design-patterns.git
synced 2026-10-12 18:16:16 +00:00
#502 Replaced usages of System.out with logger.
This commit is contained in:
1 parent
4ca205c03c
commit
0438811489
154 files changed
+1155
-792
No files matched your search
@@ -22,6 +22,9 @@
|
||||
*/
|
||||
package com.iluwatar.stepbuilder;
|
||||
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
/**
|
||||
* Step Builder Pattern
|
||||
*
|
||||
@@ -56,6 +59,8 @@ package com.iluwatar.stepbuilder;
|
||||
*/
|
||||
public class App {
|
||||
|
||||
private static final Logger LOGGER = LoggerFactory.getLogger(App.class);
|
||||
|
||||
/**
|
||||
* Program entry point
|
||||
*
|
||||
@@ -67,18 +72,18 @@ public class App {
|
||||
CharacterStepBuilder.newBuilder().name("Amberjill").fighterClass("Paladin")
|
||||
.withWeapon("Sword").noAbilities().build();
|
||||
|
||||
System.out.println(warrior);
|
||||
LOGGER.info(warrior.toString());
|
||||
|
||||
Character mage =
|
||||
CharacterStepBuilder.newBuilder().name("Riobard").wizardClass("Sorcerer")
|
||||
.withSpell("Fireball").withAbility("Fire Aura").withAbility("Teleport")
|
||||
.noMoreAbilities().build();
|
||||
|
||||
System.out.println(mage);
|
||||
LOGGER.info(mage.toString());
|
||||
|
||||
Character thief =
|
||||
CharacterStepBuilder.newBuilder().name("Desmond").fighterClass("Rogue").noWeapon().build();
|
||||
|
||||
System.out.println(thief);
|
||||
LOGGER.info(thief.toString());
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user