edu.cuny.cat.market
Class MarketQuote

java.lang.Object
  extended by edu.cuny.cat.market.MarketQuote
All Implemented Interfaces:
java.io.Serializable

public class MarketQuote
extends java.lang.Object
implements java.io.Serializable

A price quote summarising the current status of an auction.

Version:
$Revision: 1.9 $
Author:
Steve Phelps
See Also:
Serialized Form

Field Summary
protected  double ask
          The current ask-quote.
protected  double bid
          The current bid-quote.
 
Constructor Summary
MarketQuote(double ask, double bid)
           
MarketQuote(Shout ask, Shout bid)
           
 
Method Summary
 double getAsk()
           
 double getBid()
           
 double getMid()
           
 void setAsk(double ask)
           
 void setBid(double bid)
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

ask

protected double ask
The current ask-quote. Buyers need to beat this in order for their offers to get matched.


bid

protected double bid
The current bid-quote. Sellers need to ask less than this in order for their offers to get matched.

Constructor Detail

MarketQuote

public MarketQuote(double ask,
                   double bid)

MarketQuote

public MarketQuote(Shout ask,
                   Shout bid)
Method Detail

setAsk

public void setAsk(double ask)

setBid

public void setBid(double bid)

getAsk

public double getAsk()

getBid

public double getBid()

getMid

public double getMid()

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object