uuuhhhhhh
This commit is contained in:
@@ -3,6 +3,8 @@ package Logik;
|
||||
import java.util.ArrayList;
|
||||
|
||||
public class Mahlzeit {
|
||||
|
||||
private int id;
|
||||
private String name;
|
||||
private float preis;
|
||||
private ArrayList<Zutat> zutaten;
|
||||
@@ -15,6 +17,22 @@ public class Mahlzeit {
|
||||
zutaten = new ArrayList<>();
|
||||
}
|
||||
|
||||
public Mahlzeit (int id, String name, float preis, String beschreibung) {
|
||||
this.id = id;
|
||||
this.name = name;
|
||||
this.preis = preis;
|
||||
this.beschreibung = beschreibung;
|
||||
zutaten = new ArrayList<>();
|
||||
}
|
||||
|
||||
public int getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(int id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
@@ -36,4 +54,6 @@ public class Mahlzeit {
|
||||
return String.format("Name: %s, Preis: %g, Beschreibung: %s", name, preis, beschreibung);
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user