diff options
Diffstat (limited to 'src/de/fhswf/in/inf/java1/aufgabe5/Konto.java')
| -rw-r--r-- | src/de/fhswf/in/inf/java1/aufgabe5/Konto.java | 75 |
1 files changed, 75 insertions, 0 deletions
diff --git a/src/de/fhswf/in/inf/java1/aufgabe5/Konto.java b/src/de/fhswf/in/inf/java1/aufgabe5/Konto.java new file mode 100644 index 0000000..3d3aed5 --- /dev/null +++ b/src/de/fhswf/in/inf/java1/aufgabe5/Konto.java @@ -0,0 +1,75 @@ +/**
+ *
+ */
+package de.fhswf.in.inf.java1.aufgabe5;
+
+import java.math.BigDecimal;
+
+/**
+ * TODO Add comment here
+ *
+ * @author $Author: $
+ * @version $Revision: $, $Date: $ UTC
+ */
+public class Konto
+{
+
+ private BigDecimal guthaben;
+
+ private BigDecimal dispo;
+
+ private Person besitzer;
+
+ /**
+ * TODO Add constructor comment here
+ *
+ * @param besitzer
+ * Owner of the account
+ * @param dispo
+ * Dispo of the account
+ * @param guthaben
+ * Initial balance of the account
+ */
+ public Konto(Person besitzer, BigDecimal dispo, BigDecimal guthaben)
+ {
+
+ if (besitzer == null)
+ {
+ throw new IllegalArgumentException("Besitzer can't be null");
+ }
+ if (dispo == null)
+ {
+ throw new IllegalArgumentException("Dispo can't be null");
+ }
+ if (guthaben == null)
+ {
+ throw new IllegalArgumentException("Guthaben can't be null");
+ }
+
+ this.besitzer = besitzer;
+ this.dispo = dispo;
+ this.guthaben = guthaben;
+
+ }
+
+ /**
+ * TODO Add method comment here
+ *
+ * @param betrag
+ */
+ public void abheben(BigDecimal betrag)
+ {
+
+ }
+
+ /**
+ * TODO Add method comment here
+ *
+ * @param betrag
+ */
+ public void einzahlen(BigDecimal betrag)
+ {
+
+ }
+
+}
|
