Maze_Solver  1.0
A Maze Solver Algorithm for BotnRoll ONE A
Intersection Class Reference

#include <Intersection.h>

Public Member Functions

 Intersection ()
 default constructor More...
 
bool operator== (const IntersectionType &rhs) const
 operators overload More...
 
void operator= (const Intersection &rhs)
 
void setType (const IntersectionType &type)
 Sets the type of intersection. More...
 
IntersectionType getType () const
 Retrieves the type of intersection. More...
 
void resetIntersection ()
 resets intersection More...
 
MoveType checkIntersection ()
 Retrieves the type of movement to be performed after a given intersection type been recognized. More...
 
MoveType checkIntersectionInPath (Path &shortestPath)
 Retrieves the next movement of the shortest path to be performed after recognising any valid intersection. More...
 
void getIntersectionType (char lineSignature)
 Sets the intersection type after successfully recognizing a sequence of line signatures. More...
 

Public Attributes

IntersectionType _intersectionType
 the Type More...
 

Constructor & Destructor Documentation

Intersection::Intersection ( )

default constructor

Member Function Documentation

MoveType Intersection::checkIntersection ( )

Retrieves the type of movement to be performed after a given intersection type been recognized.

Parameters
intersectionTypeone of the recognized types or NONE otherwise
Returns
the type of movement to be performed by the robot (e.g. rotate 90º to the left)
MoveType Intersection::checkIntersectionInPath ( Path shortestPath)

Retrieves the next movement of the shortest path to be performed after recognising any valid intersection.

Parameters
intersectionTypeone of the recognized types or NONE otherwise
shortestPaththe shortest path computed after the exploration step
Returns
the type of movement to be performed by the robot (e.g. rotate 90º to the left)
void Intersection::getIntersectionType ( char  lineSignature)

Sets the intersection type after successfully recognizing a sequence of line signatures.

Parameters
lineSignaturethe current line type (e.g. line, turn right, turn left) observed by the line sensors
lineBinthe corresponding binary conversion
IntersectionType Intersection::getType ( ) const
inline

Retrieves the type of intersection.

void Intersection::operator= ( const Intersection rhs)
inline
bool Intersection::operator== ( const IntersectionType rhs) const
inline

operators overload

void Intersection::resetIntersection ( )

resets intersection

void Intersection::setType ( const IntersectionType type)
inline

Sets the type of intersection.

Member Data Documentation

IntersectionType Intersection::_intersectionType

the Type


The documentation for this class was generated from the following files: