mirror of
https://github.com/tiennm99/java-design-patterns.git
synced 2026-05-16 00:59:02 +00:00
Reformat rest of the design patterns - Issue #224
This commit is contained in:
@@ -7,16 +7,16 @@ package com.iluwatar.templatemethod;
|
||||
*/
|
||||
public abstract class StealingMethod {
|
||||
|
||||
protected abstract String pickTarget();
|
||||
protected abstract String pickTarget();
|
||||
|
||||
protected abstract void confuseTarget(String target);
|
||||
protected abstract void confuseTarget(String target);
|
||||
|
||||
protected abstract void stealTheItem(String target);
|
||||
protected abstract void stealTheItem(String target);
|
||||
|
||||
public void steal() {
|
||||
String target = pickTarget();
|
||||
System.out.println("The target has been chosen as " + target + ".");
|
||||
confuseTarget(target);
|
||||
stealTheItem(target);
|
||||
}
|
||||
public void steal() {
|
||||
String target = pickTarget();
|
||||
System.out.println("The target has been chosen as " + target + ".");
|
||||
confuseTarget(target);
|
||||
stealTheItem(target);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user