BAEL-4994 Class name changed in mvp
This commit is contained in:
parent
48993c9718
commit
be2d8a668f
|
@ -6,10 +6,10 @@ public class MvpMainClass {
|
||||||
|
|
||||||
Product model = retrieveProductFromDatabase();
|
Product model = retrieveProductFromDatabase();
|
||||||
ProductView view = new ProductView();
|
ProductView view = new ProductView();
|
||||||
ProductController controller = new ProductController(model, view);
|
ProductPresenter presenter = new ProductPresenter(model, view);
|
||||||
controller.showProduct();
|
presenter.showProduct();
|
||||||
controller.setProductName("SmartPhone");
|
presenter.setProductName("SmartPhone");
|
||||||
controller.showProduct();
|
presenter.showProduct();
|
||||||
}
|
}
|
||||||
|
|
||||||
private static Product retrieveProductFromDatabase() {
|
private static Product retrieveProductFromDatabase() {
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
package com.baeldung.mvp;
|
package com.baeldung.mvp;
|
||||||
|
|
||||||
public class ProductController {
|
public class ProductPresenter {
|
||||||
private final Product product;
|
private final Product product;
|
||||||
private final ProductView productView;
|
private final ProductView productView;
|
||||||
|
|
||||||
public ProductController(Product product, ProductView productView) {
|
public ProductPresenter(Product product, ProductView productView) {
|
||||||
this.product = product;
|
this.product = product;
|
||||||
this.productView = productView;
|
this.productView = productView;
|
||||||
}
|
}
|
Loading…
Reference in New Issue