jfreerails.world.accounts
Class Bill

java.lang.Object
  extended by jfreerails.world.accounts.Bill
All Implemented Interfaces:
java.io.Serializable, Transaction, FreerailsSerializable

public class Bill
extends java.lang.Object
implements Transaction

For example, the cost of buying a trains.

Author:
Luke Lindsay
See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from interface jfreerails.world.accounts.Transaction
Transaction.Category
 
Field Summary
private  Money amount
           
private  Transaction.Category category
           
private static long serialVersionUID
           
 
Constructor Summary
Bill(Money amount, Transaction.Category category)
           
 
Method Summary
 Money deltaAssets()
           
 Money deltaCash()
          Positive means credit.
 boolean equals(java.lang.Object o)
           
 Transaction.Category getCategory()
           
 int hashCode()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

serialVersionUID

private static final long serialVersionUID
See Also:
Constant Field Values

amount

private final Money amount

category

private final Transaction.Category category
Constructor Detail

Bill

public Bill(Money amount,
            Transaction.Category category)
Method Detail

deltaAssets

public Money deltaAssets()
Specified by:
deltaAssets in interface Transaction

deltaCash

public Money deltaCash()
Description copied from interface: Transaction
Positive means credit.

Specified by:
deltaCash in interface Transaction

equals

public boolean equals(java.lang.Object o)
Overrides:
equals in class java.lang.Object

getCategory

public Transaction.Category getCategory()
Specified by:
getCategory in interface Transaction

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object