net.sourceforge.jabm.strategy
Class RlStrategy
java.lang.Object
  
net.sourceforge.jabm.strategy.AbstractStrategy
      
net.sourceforge.jabm.strategy.AbstractRlStrategy
          
net.sourceforge.jabm.strategy.RlStrategy
- All Implemented Interfaces: 
 - java.io.Serializable, java.lang.Cloneable, EventListener, Taggable, Strategy, org.springframework.beans.factory.InitializingBean
 
- Direct Known Subclasses: 
 - RlStrategyWithImitation
 
public class RlStrategy
- extends AbstractRlStrategy
- implements java.io.Serializable, org.springframework.beans.factory.InitializingBean, Taggable
  
- See Also:
 - Serialized Form
 -  
 - 
 
 
 
 
 
 
 
 
| Methods inherited from class java.lang.Object | 
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
 
learner
protected StimuliResponseLearner learner
RlStrategy
public RlStrategy(Agent agent,
                  org.springframework.beans.factory.ObjectFactory<Strategy> strategyFactory,
                  StimuliResponseLearner learner)
RlStrategy
public RlStrategy(org.springframework.beans.factory.ObjectFactory<Strategy> strategyFactory,
                  StimuliResponseLearner learner)
RlStrategy
public RlStrategy()
initialise
public void initialise()
- Overrides:
 initialise in class AbstractRlStrategy
 
 
subscribeToEvents
public void subscribeToEvents(EventScheduler scheduler)
- Description copied from interface: 
Strategy 
- A Strategy should subscribe to any events it wants to receive by calling
 the 
addListener method in the EventScheduler class.
- Specified by:
 subscribeToEvents in interface Strategy- Overrides:
 subscribeToEvents in class AbstractStrategy
 
- Parameters:
 scheduler - The EventScheduler on which to listen.
 
 
execute
public void execute(java.util.List<Agent> otherAgents)
- Description copied from interface: 
Strategy 
- Execute the behaviour defined by this strategy.
- Specified by:
 execute in interface Strategy- Overrides:
 execute in class AbstractStrategy
 
- Parameters:
 otherAgents - The other agents with which the agent associated
                                                with this strategy is interacting.
 
 
getLearner
public StimuliResponseLearner getLearner()
 
 
setLearner
public void setLearner(StimuliResponseLearner learner)
 
 
setAgent
public void setAgent(Agent agent)
- Description copied from interface: 
Strategy 
- Configure the agent associated with this strategy.
- Specified by:
 setAgent in interface Strategy- Overrides:
 setAgent in class AbstractStrategy
 
 
 
clone
public Strategy clone()
               throws java.lang.CloneNotSupportedException
- Specified by:
 clone in interface Strategy- Overrides:
 clone in class AbstractStrategy
 
- Throws:
 java.lang.CloneNotSupportedException
 
setInitialPropensities
public void setInitialPropensities(double[] initialPropensities)
 
 
getNumberOfActions
public int getNumberOfActions()
- Specified by:
 getNumberOfActions in class AbstractRlStrategy
 
 
afterPropertiesSet
public void afterPropertiesSet()
                        throws java.lang.Exception
- Specified by:
 afterPropertiesSet in interface org.springframework.beans.factory.InitializingBean
 
- Throws:
 java.lang.Exception
 
setTag
public void setTag(java.lang.String tag)
- Specified by:
 setTag in interface Taggable
 
 
getTag
public java.lang.String getTag()
- Specified by:
 getTag in interface Taggable