uk.ac.liv.auction.agent
Class FixedValuer

java.lang.Object
  extended byuk.ac.liv.auction.agent.FixedValuer
All Implemented Interfaces:
AuctionEventListener, Parameterizable, Resetable, java.io.Serializable, ValuationPolicy
Direct Known Subclasses:
IntervalValuer

public class FixedValuer
extends java.lang.Object
implements ValuationPolicy, java.io.Serializable

A valuation policy in which we maintain a fixed private valuation independent of time or auction.

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

Field Summary
static java.lang.String P_VALUE
           
protected  double value
           
 
Constructor Summary
FixedValuer()
           
FixedValuer(double value)
           
 
Method Summary
 void consumeUnit(Auction auction)
          Recalculate valuation after consumption of the commodity being traded in the given auction.
 double determineValue(Auction auction)
          Determine the current valuation of commodity in the given auction.
 void eventOccurred(AuctionEvent event)
          Recalculate valuation(s) in response to an auction event.
 void reset()
          Reinitialise our state to the original settings.
 void setup(ec.util.ParameterDatabase parameters, ec.util.Parameter base)
          Initialise this object from a parameter database.
 void setValue(double value)
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

value

protected double value

P_VALUE

public static final java.lang.String P_VALUE
See Also:
Constant Field Values
Constructor Detail

FixedValuer

public FixedValuer()

FixedValuer

public FixedValuer(double value)
Method Detail

setup

public void setup(ec.util.ParameterDatabase parameters,
                  ec.util.Parameter base)
Description copied from interface: Parameterizable
Initialise this object from a parameter database.

Specified by:
setup in interface Parameterizable

determineValue

public double determineValue(Auction auction)
Description copied from interface: ValuationPolicy
Determine the current valuation of commodity in the given auction.

Specified by:
determineValue in interface ValuationPolicy

consumeUnit

public void consumeUnit(Auction auction)
Description copied from interface: ValuationPolicy
Recalculate valuation after consumption of the commodity being traded in the given auction.

Specified by:
consumeUnit in interface ValuationPolicy

eventOccurred

public void eventOccurred(AuctionEvent event)
Description copied from interface: ValuationPolicy
Recalculate valuation(s) in response to an auction event.

Specified by:
eventOccurred in interface ValuationPolicy

reset

public void reset()
Description copied from interface: Resetable
Reinitialise our state to the original settings.

Specified by:
reset in interface Resetable

setValue

public void setValue(double value)

toString

public java.lang.String toString()