File tree Expand file tree Collapse file tree 3 files changed +16
-4
lines changed
layers/src/main/java/com/iluwatar/layers Expand file tree Collapse file tree 3 files changed +16
-4
lines changed Original file line number Diff line number Diff line change 33import java .util .Arrays ;
44
55public class App {
6+
7+ private static CakeBakingService cakeBakingService = new CakeBakingServiceImpl ();
68
79 public static void main (String [] args ) {
8- CakeBakingService cakeBakingService = new CakeBakingServiceImpl ();
10+
11+ // initialize example data
912 initializeData (cakeBakingService );
10- CakeView cakeView = new CakeView (cakeBakingService );
13+
14+ // create view and render it
15+ CakeViewImpl cakeView = new CakeViewImpl (cakeBakingService );
1116 cakeView .render ();
1217 }
1318
Original file line number Diff line number Diff line change 11package com .iluwatar .layers ;
22
3- public class CakeView {
3+ public class CakeViewImpl implements View {
44
55 private CakeBakingService cakeBakingService ;
66
7- public CakeView (CakeBakingService cakeBakingService ) {
7+ public CakeViewImpl (CakeBakingService cakeBakingService ) {
88 this .cakeBakingService = cakeBakingService ;
99 }
1010
Original file line number Diff line number Diff line change 1+ package com .iluwatar .layers ;
2+
3+ public interface View {
4+
5+ void render ();
6+
7+ }
You can’t perform that action at this time.
0 commit comments