org.moyoman.module.ladder.ladderimpl
Class LadderInfo

java.lang.Object
  |
  +--org.moyoman.module.ladder.ladderimpl.LadderInfo
All Implemented Interfaces:
Cloneable, Serializable

class LadderInfo
extends Object
implements Cloneable, Serializable

This class is used for storing information about ladders.


Field Summary
private  Set breakers
          Each element is a Stone which is a ladder breaker.
private  boolean isCaught
          Indicates if the ladder or potential ladder works or not.
private  MoveDescriptorForest sequences
          Best play for both ladders and potential ladders.
private  Set threats
          Each element is a Stone which is a threat to capture the ladder.
 
Constructor Summary
protected LadderInfo(MoveDescriptorForest mdf)
           
 
Method Summary
protected  void addLadderBreaker(Stone st)
           
protected  void addLadderBreakers(Set s)
           
protected  void addLadderThreat(Stone st)
           
protected  void addLadderThreats(Set s)
           
 Object clone()
           
protected  Set getLadderBreakers()
           
protected  Set getLadderThreats()
           
protected  MoveDescriptorForest getSequences()
           
protected  boolean isCaught()
           
protected  void setIsCaught(boolean flag)
           
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

sequences

private MoveDescriptorForest sequences
Best play for both ladders and potential ladders.


isCaught

private boolean isCaught
Indicates if the ladder or potential ladder works or not.


breakers

private Set breakers
Each element is a Stone which is a ladder breaker.


threats

private Set threats
Each element is a Stone which is a threat to capture the ladder.

Constructor Detail

LadderInfo

protected LadderInfo(MoveDescriptorForest mdf)
Method Detail

getSequences

protected MoveDescriptorForest getSequences()

isCaught

protected boolean isCaught()

getLadderBreakers

protected Set getLadderBreakers()

getLadderThreats

protected Set getLadderThreats()

setIsCaught

protected void setIsCaught(boolean flag)

addLadderBreaker

protected void addLadderBreaker(Stone st)

addLadderThreat

protected void addLadderThreat(Stone st)

addLadderBreakers

protected void addLadderBreakers(Set s)

addLadderThreats

protected void addLadderThreats(Set s)

clone

public Object clone()
Overrides:
clone in class Object