Interface PuzzleNotation<P extends TwistyPuzzle>

All Known Implementing Classes:
SingmasterNotation, SquareOneNotation

public interface PuzzleNotation<P extends TwistyPuzzle>

Represents a notation for describing sequences of twists in twisty puzzle such as Singmaster Notation for the Rubik's Cube.

Method Summary
 Twist[] getTwists(java.lang.String description, P puzzle)
          Gets the sequence of twists determined by the description.

Method Detail


Twist[] getTwists(java.lang.String description,
                  P puzzle)
Gets the sequence of twists determined by the description. This should return an array of instances of classes which will be accepted (will not throw ClassCastException) by the implementation of TwistyPuzzle.twist(Twist) in the class P, although they may not be possible from all positions of the puzzle (or even the current position of the puzzle argument).

description - the twists in this notation
puzzle - a prototype puzzle to use in case the puzzle type itself has parameters necessary for interpreting the notation
the twists specified