simulations.core.strategy.completeStrategy
Class AltruistStrategy

java.lang.Object
  extended by simulations.core.strategy.Strategy
      extended by simulations.core.strategy.completeStrategy.CompleteStrategy
          extended by simulations.core.strategy.completeStrategy.GenericComposedStrategy
              extended by simulations.core.strategy.completeStrategy.AltruistStrategy
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable

public class AltruistStrategy
extends GenericComposedStrategy

See Also:
Serialized Form

Field Summary
 
Fields inherited from class simulations.core.strategy.completeStrategy.CompleteStrategy
askingStrategyVector, attackStrategyVector, decisionStrategyVector
 
Fields inherited from class simulations.core.strategy.Strategy
abr, memory, name, randomGenerator
 
Constructor Summary
AltruistStrategy()
          Creates a new instance of AltruistStrategy
 
Method Summary
 void updateAttacksInfos(Player player, java.util.ArrayList attacksList)
          This method is called by the judge after the decision of players to attack and to ask supports to inform the strategy
 
Methods inherited from class simulations.core.strategy.completeStrategy.GenericComposedStrategy
getDescription, getPlayersToAskSupport, getPlayerToAttack, supportAttack, updateLastTurn
 
Methods inherited from class simulations.core.strategy.completeStrategy.CompleteStrategy
equals, getAskingComposition, getAskingStrategyVector, getAttackComposition, getAttackStrategyVector, getDecisionComposition, getDecisionStrategyVector, setAskingStrategyVector, setAttackStrategyVector, setDecisionStrategyVector
 
Methods inherited from class simulations.core.strategy.Strategy
getAbr, getMemory, getName, getRandomGenerator, setAbr, setMemory, setName, setRandomGenerator, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

AltruistStrategy

public AltruistStrategy()
Creates a new instance of AltruistStrategy

Method Detail

updateAttacksInfos

public void updateAttacksInfos(Player player,
                               java.util.ArrayList attacksList)
This method is called by the judge after the decision of players to attack and to ask supports to inform the strategy

Overrides:
updateAttacksInfos in class GenericComposedStrategy
Parameters:
player - The owner of the strategy
attacksList - The list of attacks