jfreerails.client.view
Class IncomeStatementGenerator

java.lang.Object
  extended by jfreerails.client.view.IncomeStatementGenerator

public class IncomeStatementGenerator
extends java.lang.Object

Generates the income statement- note, its fields are read using reflection so don't change their names.

Author:
Luke

Field Summary
 Money bulkFreightTotal
           
 Money bulkFreightYtd
           
private  GameCalendar cal
           
 Money fastFreightTotal
           
 Money fastFreightYtd
           
(package private)  GameTime from
           
 Money interestTotal
           
 Money interestYtd
           
 Money mailTotal
           
 Money mailYtd
           
 Money passengersTotal
           
 Money passengersYtd
           
(package private)  FreerailsPrincipal principal
           
 Money profitTotal
           
 Money profitYtd
           
 Money slowFreightTotal
           
 Money slowFreightYtd
           
private  int startyear
           
 Money stationMaintenanceTotal
           
 Money stationMaintenanceYtd
           
(package private)  GameTime to
           
 Money trackMaintenanceTotal
           
 Money trackMaintenanceYtd
           
 Money trainMaintenanceTotal
           
 Money trainMaintenanceYtd
           
(package private)  ReadOnlyWorld w
           
 java.lang.String year
           
 
Constructor Summary
IncomeStatementGenerator(ReadOnlyWorld w, FreerailsPrincipal principal)
           
 
Method Summary
(package private)  Money calRevenue(java.lang.String cargoCategory)
           
private  Money calTotal(Transaction.Category transactionCategory)
           
(package private)  Money calTrainRevenue(int trainId)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

from

GameTime from

to

GameTime to

w

final ReadOnlyWorld w

principal

final FreerailsPrincipal principal

startyear

private int startyear

cal

private GameCalendar cal

mailTotal

public Money mailTotal

passengersTotal

public Money passengersTotal

fastFreightTotal

public Money fastFreightTotal

slowFreightTotal

public Money slowFreightTotal

bulkFreightTotal

public Money bulkFreightTotal

interestTotal

public Money interestTotal

trainMaintenanceTotal

public Money trainMaintenanceTotal

trackMaintenanceTotal

public Money trackMaintenanceTotal

stationMaintenanceTotal

public Money stationMaintenanceTotal

profitTotal

public Money profitTotal

mailYtd

public Money mailYtd

passengersYtd

public Money passengersYtd

fastFreightYtd

public Money fastFreightYtd

slowFreightYtd

public Money slowFreightYtd

bulkFreightYtd

public Money bulkFreightYtd

interestYtd

public Money interestYtd

trainMaintenanceYtd

public Money trainMaintenanceYtd

trackMaintenanceYtd

public Money trackMaintenanceYtd

stationMaintenanceYtd

public Money stationMaintenanceYtd

profitYtd

public Money profitYtd

year

public java.lang.String year
Constructor Detail

IncomeStatementGenerator

IncomeStatementGenerator(ReadOnlyWorld w,
                         FreerailsPrincipal principal)
Method Detail

calRevenue

Money calRevenue(java.lang.String cargoCategory)

calTrainRevenue

Money calTrainRevenue(int trainId)

calTotal

private Money calTotal(Transaction.Category transactionCategory)