net.sourceforge.jasa.market.rules
Class MaxRoundsDayEndingCondition

java.lang.Object
  extended by net.sourceforge.jasa.market.rules.TimingCondition
      extended by net.sourceforge.jasa.market.rules.MaxRoundsDayEndingCondition
All Implemented Interfaces:
DayEndingCondition

public class MaxRoundsDayEndingCondition
extends TimingCondition
implements DayEndingCondition

The interface for expressing the condition of closing an market.

 

Field Summary
protected  int lengthOfDay
          The maximum length in rounds of a trading day
static java.lang.String P_LENGTH_OF_DAY
           
 
Fields inherited from interface net.sourceforge.jasa.market.rules.DayEndingCondition
P_DEF_BASE
 
Constructor Summary
MaxRoundsDayEndingCondition()
           
MaxRoundsDayEndingCondition(Market auction)
           
 
Method Summary
 boolean eval()
           
 int getLengthOfDay()
           
 int getRemainingRounds()
           
 void setLengthOfDay(int lengthOfDay)
           
 
Methods inherited from class net.sourceforge.jasa.market.rules.TimingCondition
getAuction, setAuction
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

P_LENGTH_OF_DAY

public static final java.lang.String P_LENGTH_OF_DAY
See Also:
Constant Field Values

lengthOfDay

protected int lengthOfDay
The maximum length in rounds of a trading day

Constructor Detail

MaxRoundsDayEndingCondition

public MaxRoundsDayEndingCondition()

MaxRoundsDayEndingCondition

public MaxRoundsDayEndingCondition(Market auction)
Method Detail

getLengthOfDay

public int getLengthOfDay()

setLengthOfDay

public void setLengthOfDay(int lengthOfDay)

eval

public boolean eval()
Specified by:
eval in class TimingCondition

getRemainingRounds

public int getRemainingRounds()