added lab2 ex1

This commit is contained in:
2024-10-07 09:00:49 +02:00
parent 8fadc54ab2
commit 2f41073a0f
16 changed files with 143 additions and 0 deletions

View File

@@ -0,0 +1,14 @@
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 + "')";
}
}