com.carlosbcruz.pegsolitaire
Class OnlyOneProblem
java.lang.Object
com.carlosbcruz.pegsolitaire.OnlyOneProblem
- All Implemented Interfaces:
- Problem, java.lang.Cloneable
public class OnlyOneProblem
- extends java.lang.Object
- implements Problem
Represent one problem.
- Author:
- Carlos Fernando Bella Cruz - pessoal@carlosbcruz.com
Constructor Summary |
OnlyOneProblem()
Default constructor |
OnlyOneProblem(java.lang.String Arq)
Constructor that receives the problem file name |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
OnlyOneProblem
public OnlyOneProblem()
- Default constructor
OnlyOneProblem
public OnlyOneProblem(java.lang.String Arq)
- Constructor that receives the problem file name
- Parameters:
Arq
- the problem file name
apply
public void apply(Possibility possib)
- Specified by:
apply
in interface Problem
toString
public java.lang.String toString()
- Specified by:
toString
in interface Problem
- Overrides:
toString
in class java.lang.Object
getPossibilities
public java.util.Vector getPossibilities()
- Specified by:
getPossibilities
in interface Problem
isSolved
public boolean isSolved()
- Specified by:
isSolved
in interface Problem
clone
public java.lang.Object clone()
throws java.lang.CloneNotSupportedException
- Specified by:
clone
in interface Problem
- Overrides:
clone
in class java.lang.Object
- Throws:
java.lang.CloneNotSupportedException