de.upb.swtpra05.group03.companycontrol
Class StockInformation

java.lang.Object
  extended byde.upb.swtpra05.group03.companycontrol.StockInformation

public class StockInformation
extends java.lang.Object

Storage Class which stores Stock Informations for a Station

Version:
$Revision: 1.3 $

Field Summary
private  int buysFor
          the price the station buys a shuttle for
private  int currentNumberOfOrders
          the current number of orders with this station as start station
private  int sellsFor
          the price the station sells its shuttles for
private  int stationID
          the ID of the station
private  java.lang.String stationName
          the Name linked to the ID
private  int stock
          the amount of shuttles available at the station
private  int totalNumberOfOrders
          the total number of orders with this station as start station
 
Constructor Summary
StockInformation()
          Constructor of StockInformation
StockInformation(int stationID, int stock, int buysFor, int sellsFor)
          Overloaded constructor of StockInformation
 
Method Summary
 int getBuysFor()
          accessor method for getting the price to buy for
 int getCurrentNumberOfOrders()
           
 int getSellsFor()
          accessor method for getting the price to sell for
 int getStationID()
          accessor method for getting the stationID
 java.lang.String getStationName()
          accessor method for getting the stationName
 int getStock()
          accessor method for getting the stock amount
 int getTotalNumberOfOrders()
           
 void setBuysFor(int buysFor)
          accessor method for setting the price to buy for
 void setCurrentNumberOfOrders(int currentNumberOfOrders)
           
 void setSellsFor(int sellsFor)
          accessor method for setting the price to sell for
 void setStationID(int stationID)
          accessor method for setting the stationID
 void setStationName(java.lang.String stationName)
          accessor method for setting the stationName
 void setStock(int stock)
          accessor method for setting the stock amount
 void setTotalNumberOfOrders(int totalNumberOfOrders)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

stationID

private int stationID
the ID of the station


stationName

private java.lang.String stationName
the Name linked to the ID


stock

private int stock
the amount of shuttles available at the station


sellsFor

private int sellsFor
the price the station sells its shuttles for


buysFor

private int buysFor
the price the station buys a shuttle for


totalNumberOfOrders

private int totalNumberOfOrders
the total number of orders with this station as start station


currentNumberOfOrders

private int currentNumberOfOrders
the current number of orders with this station as start station

Constructor Detail

StockInformation

public StockInformation()
Constructor of StockInformation


StockInformation

public StockInformation(int stationID,
                        int stock,
                        int buysFor,
                        int sellsFor)
Overloaded constructor of StockInformation

Parameters:
stationID - the station ID
stock - the amount of offered shuttles
sellsFor - the price to sell a shuttle for
buysFor - the price to buy a shuttle for
Method Detail

setStationID

public void setStationID(int stationID)
accessor method for setting the stationID

Parameters:
stationID - see above

setStationName

public void setStationName(java.lang.String stationName)
accessor method for setting the stationName

Parameters:
stationName - see above

setStock

public void setStock(int stock)
accessor method for setting the stock amount

Parameters:
stock - see above

setSellsFor

public void setSellsFor(int sellsFor)
accessor method for setting the price to sell for

Parameters:
sellsFor - see above

setBuysFor

public void setBuysFor(int buysFor)
accessor method for setting the price to buy for

Parameters:
buysFor - see above

setTotalNumberOfOrders

public void setTotalNumberOfOrders(int totalNumberOfOrders)
Parameters:
totalNumberOfOrders - The numberOfOrders to set.

setCurrentNumberOfOrders

public void setCurrentNumberOfOrders(int currentNumberOfOrders)
Parameters:
currentNumberOfOrders - The numberOfOrders to set.

getStationID

public int getStationID()
accessor method for getting the stationID

Returns:
see above

getStationName

public java.lang.String getStationName()
accessor method for getting the stationName

Returns:
see above

getStock

public int getStock()
accessor method for getting the stock amount

Returns:
see above

getSellsFor

public int getSellsFor()
accessor method for getting the price to sell for

Returns:
see above

getBuysFor

public int getBuysFor()
accessor method for getting the price to buy for

Returns:
see above

getTotalNumberOfOrders

public int getTotalNumberOfOrders()
Returns:
Returns the totalNumberOfOrders.

getCurrentNumberOfOrders

public int getCurrentNumberOfOrders()
Returns:
Returns the totalNumberOfOrders.