diff options
Diffstat (limited to 'bank-eiffel')
| -rw-r--r-- | bank-eiffel/account.e | 14 | ||||
| -rw-r--r-- | bank-eiffel/retiree.e | 13 | ||||
| -rw-r--r-- | bank-eiffel/retireeaccount.e | 13 | ||||
| -rw-r--r-- | bank-eiffel/student.e | 13 | ||||
| -rw-r--r-- | bank-eiffel/studentaccount.e | 13 |
5 files changed, 66 insertions, 0 deletions
diff --git a/bank-eiffel/account.e b/bank-eiffel/account.e index 578aec2..6c240de 100644 --- a/bank-eiffel/account.e +++ b/bank-eiffel/account.e | |||
| @@ -12,6 +12,9 @@ inherit | |||
| 12 | 12 | ||
| 13 | feature -- Access | 13 | feature -- Access |
| 14 | 14 | ||
| 15 | transfer_minamount: REAL_32 assign set_transfer_minamount | ||
| 16 | -- Mindestbetrag für jede Einzahlung, Auszahlung und Überweisung | ||
| 17 | |||
| 15 | authorized_signers: SET [PERSON] assign set_authorized_signers | 18 | authorized_signers: SET [PERSON] assign set_authorized_signers |
| 16 | -- Zeichnungsberechtigte | 19 | -- Zeichnungsberechtigte |
| 17 | attribute Result := ({like authorized_signers}).default end --| Remove line when Void Safety is properly set | 20 | attribute Result := ({like authorized_signers}).default end --| Remove line when Void Safety is properly set |
| @@ -30,6 +33,16 @@ feature -- Access | |||
| 30 | 33 | ||
| 31 | feature -- Element change | 34 | feature -- Element change |
| 32 | 35 | ||
| 36 | set_transfer_minamount (a_transfer_minamount: like transfer_minamount) | ||
| 37 | -- Assign `transfer_minamount' with `a_transfer_minamount'. | ||
| 38 | require | ||
| 39 | a_transfer_minamount_positive: a_transfer_minamount > 0.0 | ||
| 40 | do | ||
| 41 | transfer_minamount := a_transfer_minamount | ||
| 42 | ensure | ||
| 43 | transfer_minamount_assigned: transfer_minamount = a_transfer_minamount | ||
| 44 | end | ||
| 45 | |||
| 33 | set_authorized_signers (an_authorized_signers: like authorized_signers) | 46 | set_authorized_signers (an_authorized_signers: like authorized_signers) |
| 34 | -- Assign `authorized_signers' with `an_authorized_signers'. | 47 | -- Assign `authorized_signers' with `an_authorized_signers'. |
| 35 | require | 48 | require |
| @@ -72,4 +85,5 @@ invariant | |||
| 72 | interest_debit_within_bounds: interest_debit >= 0.0 and interest_debit <= 1.0 | 85 | interest_debit_within_bounds: interest_debit >= 0.0 and interest_debit <= 1.0 |
| 73 | interest_deposit_within_bounds: interest_deposit >= 0.0 and interest_deposit <= 1.0 | 86 | interest_deposit_within_bounds: interest_deposit >= 0.0 and interest_deposit <= 1.0 |
| 74 | authorized_signers_attached: authorized_signers /= Void | 87 | authorized_signers_attached: authorized_signers /= Void |
| 88 | transfer_minamount_positive: transfer_minamount > 0.0 | ||
| 75 | end | 89 | end |
diff --git a/bank-eiffel/retiree.e b/bank-eiffel/retiree.e new file mode 100644 index 0000000..57e5d05 --- /dev/null +++ b/bank-eiffel/retiree.e | |||
| @@ -0,0 +1,13 @@ | |||
| 1 | note | ||
| 2 | description: "Summary description for {RETIREE}." | ||
| 3 | author: "" | ||
| 4 | date: "$Date$" | ||
| 5 | revision: "$Revision$" | ||
| 6 | |||
| 7 | class | ||
| 8 | RETIREE | ||
| 9 | |||
| 10 | inherit | ||
| 11 | PERSON | ||
| 12 | |||
| 13 | end | ||
diff --git a/bank-eiffel/retireeaccount.e b/bank-eiffel/retireeaccount.e new file mode 100644 index 0000000..3b935d7 --- /dev/null +++ b/bank-eiffel/retireeaccount.e | |||
| @@ -0,0 +1,13 @@ | |||
| 1 | note | ||
| 2 | description: "Summary description for {RETIREEACCOUNT}." | ||
| 3 | author: "" | ||
| 4 | date: "$Date$" | ||
| 5 | revision: "$Revision$" | ||
| 6 | |||
| 7 | class | ||
| 8 | RETIREEACCOUNT | ||
| 9 | |||
| 10 | inherit | ||
| 11 | ACCOUNT | ||
| 12 | |||
| 13 | end | ||
diff --git a/bank-eiffel/student.e b/bank-eiffel/student.e new file mode 100644 index 0000000..2b5afd4 --- /dev/null +++ b/bank-eiffel/student.e | |||
| @@ -0,0 +1,13 @@ | |||
| 1 | note | ||
| 2 | description: "Summary description for {STUDENT}." | ||
| 3 | author: "" | ||
| 4 | date: "$Date$" | ||
| 5 | revision: "$Revision$" | ||
| 6 | |||
| 7 | class | ||
| 8 | STUDENT | ||
| 9 | |||
| 10 | inherit | ||
| 11 | PERSON | ||
| 12 | |||
| 13 | end | ||
diff --git a/bank-eiffel/studentaccount.e b/bank-eiffel/studentaccount.e new file mode 100644 index 0000000..831cb6a --- /dev/null +++ b/bank-eiffel/studentaccount.e | |||
| @@ -0,0 +1,13 @@ | |||
| 1 | note | ||
| 2 | description: "Summary description for {STUDENTACCOUNT}." | ||
| 3 | author: "" | ||
| 4 | date: "$Date$" | ||
| 5 | revision: "$Revision$" | ||
| 6 | |||
| 7 | class | ||
| 8 | STUDENTACCOUNT | ||
| 9 | |||
| 10 | inherit | ||
| 11 | ACCOUNT | ||
| 12 | |||
| 13 | end | ||
