diff --git a/chapter6/haesa/refactor-chapter6-1.java b/chapter6/haesa/refactor-chapter6-1.java new file mode 100644 index 0000000..e44a420 --- /dev/null +++ b/chapter6/haesa/refactor-chapter6-1.java @@ -0,0 +1,12 @@ +// What is the difference between the following codes? + +// 가솔린 차만 사용 가능하다는 제약이 있음 +public interface Vehicle { + double getFuelTankCapacityInGallons(); + double getGallonsOfGasoline(); +} + +// 연료 종류에 상관 없이 사용 가능 +public interface Vehicle { + double getPercentFuelRemaining(); +} \ No newline at end of file