15 lines
312 B
Java
15 lines
312 B
Java
package learn.simple_factory_method;
|
|
|
|
public class ConcreteProduct implements Product {
|
|
private String category;
|
|
|
|
public ConcreteProduct(String category) {
|
|
this.category = category;
|
|
}
|
|
|
|
@Override
|
|
public String toString() {
|
|
return "ConcreteProduct('" + category + "')";
|
|
}
|
|
}
|