diff --git a/src/main/java/temppackage/Transaction.java b/src/main/java/temppackage/Transaction.java index ae4a355..6a000ec 100644 --- a/src/main/java/temppackage/Transaction.java +++ b/src/main/java/temppackage/Transaction.java @@ -7,13 +7,13 @@ public abstract class Transaction { private Share share; private int week; private TransactionCalculator transactionCalculator; - private boolean commited; + private boolean committed; protected Transaction(Share share, int week, TransactionCalculator transactionCalculator) { this.share = share; this.week = week; this.transactionCalculator = transactionCalculator; - this.commited = commited; + this.committed = false; } public Share getShare() { @@ -29,11 +29,12 @@ public TransactionCalculator getCalculator() { } public boolean isCommitted() { - return this.commited; + return this.committed; } - public void commit(Player player) { - // TODO - this.commited = true; + protected void setCommitted(boolean committed) { + this.committed = committed; } + + public abstract void commit(Player player); }