org.jscience.economics
Class Economy

java.lang.Object
  extended by org.jscience.economics.Economy

public abstract class Economy
extends java.lang.Object

A class representing a society with money (goods are not exchanged from hand to hand but using the medium of money). Especially, it defines the complete flow from raw materials to a product with a unique serial number.


Constructor Summary
Economy(java.util.Set orgs, Bank centralBank)
          Creates a new Economy object.
 
Method Summary
 void addOrganization(Organization org)
          DOCUMENT ME!
 java.util.Set getAllResources()
          DOCUMENT ME!
 Bank getCentralBank()
          DOCUMENT ME!
 Amount getNumberOfUnits(Resource resource)
          DOCUMENT ME!
 java.util.Set getOrganizations()
          DOCUMENT ME!
 java.util.Set getOwners(Resource resource)
          DOCUMENT ME!
 Money[] getPrices(Resource resource)
          DOCUMENT ME!
 Amount<Money> getValue()
          DOCUMENT ME!
 void removeOrganization(Organization org)
          DOCUMENT ME!
 void setCentralBank(Bank bank)
          DOCUMENT ME!
abstract  void step(double dt)
          DOCUMENT ME!
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Economy

public Economy(java.util.Set orgs,
               Bank centralBank)
Creates a new Economy object.

Parameters:
orgs - DOCUMENT ME!
centralBank - DOCUMENT ME!
Method Detail

getOrganizations

public java.util.Set getOrganizations()
DOCUMENT ME!

Returns:
DOCUMENT ME!

getCentralBank

public Bank getCentralBank()
DOCUMENT ME!

Returns:
DOCUMENT ME!

addOrganization

public void addOrganization(Organization org)
DOCUMENT ME!

Parameters:
org - DOCUMENT ME!
Throws:
java.lang.IllegalArgumentException - DOCUMENT ME!

removeOrganization

public void removeOrganization(Organization org)
DOCUMENT ME!

Parameters:
org - DOCUMENT ME!
Throws:
java.lang.IllegalArgumentException - DOCUMENT ME!

setCentralBank

public void setCentralBank(Bank bank)
DOCUMENT ME!

Parameters:
bank - DOCUMENT ME!

getPrices

public Money[] getPrices(Resource resource)
DOCUMENT ME!

Parameters:
resource - DOCUMENT ME!
Returns:
DOCUMENT ME!

getNumberOfUnits

public Amount getNumberOfUnits(Resource resource)
DOCUMENT ME!

Parameters:
resource - DOCUMENT ME!
Returns:
DOCUMENT ME!

getAllResources

public java.util.Set getAllResources()
DOCUMENT ME!

Returns:
DOCUMENT ME!

getValue

public Amount<Money> getValue()
DOCUMENT ME!

Returns:
DOCUMENT ME!

getOwners

public java.util.Set getOwners(Resource resource)
DOCUMENT ME!

Parameters:
resource - DOCUMENT ME!
Returns:
DOCUMENT ME!
Throws:
java.lang.IllegalArgumentException - DOCUMENT ME!

step

public abstract void step(double dt)
DOCUMENT ME!

Parameters:
dt - DOCUMENT ME!