art.cs
Class Accounting

java.lang.Object
  extended byart.cs.Accounting
All Implemented Interfaces:
Author

public class Accounting
extends java.lang.Object
implements Author

The accounting class is the entity to which all the taxes are payed and is used to account the aggregate wealth of the simulated economy represented by the classifier system. If a message has not an owner (in other word if it has been created by the environment) its author is Accounting and the collected money go to this class's asset.

Author:
Marco Lamieri and Gianluigi Ferraris

Constructor Summary
Accounting()
          Constructor of the class.
 
Method Summary
 void collect(double money)
          The implementing class collect the money payed by the winner of the auction to it's author.
 double getAsset()
          Get the asset owned by the accounting (and than not owned by the classifiers)
 void pay(double cash)
          Accounting pay money.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Accounting

public Accounting()
Constructor of the class.

Method Detail

collect

public void collect(double money)
Description copied from interface: Author
The implementing class collect the money payed by the winner of the auction to it's author.

Specified by:
collect in interface Author
Parameters:
money - Money collected.

getAsset

public double getAsset()
Get the asset owned by the accounting (and than not owned by the classifiers)

Returns:
Accounter's asset

pay

public void pay(double cash)
Accounting pay money.

Parameters:
cash - Money payed.