edu.cuny.cat.market.charging
Class SerialChargingPolicy
java.lang.Object
edu.cuny.cat.market.AuctioneerPolicy
edu.cuny.cat.market.charging.ChargingPolicy
edu.cuny.cat.market.charging.CombiChargingPolicy
edu.cuny.cat.market.charging.SerialChargingPolicy
- All Implemented Interfaces:
- AuctionEventListener, edu.cuny.config.param.Parameterizable, edu.cuny.obj.Resetable
public class SerialChargingPolicy
- extends CombiChargingPolicy
A charging policy that divides the duration of a game into several phases and
use one of its child charging policies during each phase.
Parameters
base.i
int |
(the parameter base of the ith phase) |
base.i.start
int |
(the start day of the ith phase (inclusive)) |
base.i.end
int |
(the end day of the ith phase (inclusive)) |
- Version:
- $Revision: 1.23 $
- Author:
- Jinzhong Niu
Field Summary |
static java.lang.String |
P_END
|
static java.lang.String |
P_START
|
protected edu.cuny.cat.market.charging.SerialChargingPolicy.ChargingPhase[] |
phases
|
Fields inherited from class edu.cuny.cat.market.charging.ChargingPolicy |
FEE_TYPES, fees, FLAT, FRACTIONAL, INFORMATION_INDEX, MAXES, MINES, P_DEF_BASE, P_FEES, PROFIT_INDEX, REGISTRATION_INDEX, SHOUT_INDEX, TRANSACTION_INDEX |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
P_START
public static final java.lang.String P_START
- See Also:
- Constant Field Values
P_END
public static final java.lang.String P_END
- See Also:
- Constant Field Values
phases
protected edu.cuny.cat.market.charging.SerialChargingPolicy.ChargingPhase[] phases
SerialChargingPolicy
public SerialChargingPolicy()
setup
public void setup(edu.cuny.config.param.ParameterDatabase parameters,
edu.cuny.config.param.Parameter base)
- Specified by:
setup
in interface edu.cuny.config.param.Parameterizable
- Overrides:
setup
in class CombiChargingPolicy
eventOccurred
public void eventOccurred(AuctionEvent event)
- Specified by:
eventOccurred
in interface AuctionEventListener
- Overrides:
eventOccurred
in class AuctioneerPolicy
findPhase
protected int findPhase(int day)
toString
public java.lang.String toString()
- Overrides:
toString
in class CombiChargingPolicy