maze.structure
Class MazeFillerSimple

java.lang.Object
  extended bymaze.structure.MazeFiller
      extended bymaze.structure.MazeFillerSimple

public class MazeFillerSimple
extends MazeFiller

A simple MazeFiller with no retry on collision, no bending of straight paths.


Field Summary
 
Fields inherited from class maze.structure.MazeFiller
branch, theOpenEnds, theRNG
 
Constructor Summary
MazeFillerSimple()
          Constructs a new MazeFillerSimple.
MazeFillerSimple(PushPop p)
          Constructs a new MazeFillerRetry with the given PushPop; either a Stack or a Queue.
MazeFillerSimple(PushPop p, double b)
          Constructs a new MazeFillerRetry with the given PushPop (either a Stack or a Queue) and a given branching factor between 0.0 and 1.0.
 
Method Summary
 void finish(Maze m)
          Finishes the maze filling process.
 void start(Maze m)
          Starts filling the maze with Cells.
 
Methods inherited from class maze.structure.MazeFiller
branch, next, straight
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MazeFillerSimple

public MazeFillerSimple()
Constructs a new MazeFillerSimple. Uses a LIFO and 0.50 branching factor.


MazeFillerSimple

public MazeFillerSimple(PushPop p)
Constructs a new MazeFillerRetry with the given PushPop; either a Stack or a Queue. The branching factor is 0.50.

Parameters:
p - PushPop to use, either Stack or Queue.

MazeFillerSimple

public MazeFillerSimple(PushPop p,
                        double b)
Constructs a new MazeFillerRetry with the given PushPop (either a Stack or a Queue) and a given branching factor between 0.0 and 1.0.

Parameters:
p - PushPop to use, either Stack or Queue.
b - double branching factor between 0.0 and 1.0.
Method Detail

start

public void start(Maze m)
Starts filling the maze with Cells.

Overrides:
start in class MazeFiller
Parameters:
m - The Maze to fill.

finish

public void finish(Maze m)
Finishes the maze filling process.

Overrides:
finish in class MazeFiller
Parameters:
m - The Maze to fill.