Main Page | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | Related Pages

ArMap Class Reference

This is a class for maps made with ScanStudio and Mapper3. More...

#include <ArMap.h>

List of all members.

Public Types

enum  { INFO_COUNT = LAST_INFO + 1 }
enum  InfoType { TASK_INFO, ROUTE_INFO, LAST_INFO = ROUTE_INFO }
 List of the standard Info categories defined for the map. More...

Public Member Functions

void addMapChangedCB (ArFunctor *functor, ArListPos::Pos position=ArListPos::LAST)
 Adds a callback called when the map is changed.
 ArMap (const char *baseDirectory="./", bool addToGlobalConfig=true, const char *configSection="Files", const char *configParam="Map", const char *configDesc="Map of the environment we'll use to navigate", bool ignoreEmptyFileName=true)
 Constructor.
ArMapObjectfindMapObject (const char *name, const char *type=NULL)
 Gets a map object of given name and type if it exists.
const char * getBaseDirectory (void) const
 Gets the base directory.
const char * getFileName (void) const
 Gets the fileName that was loaded.
bool getIgnoreEmptyFileName (void)
 Gets whether we ignore empty file names or fail if we encounter one.
std::list< ArArgumentBuilder * > * getInfo (int infoType)
 Gets the strings for the specified Info category.
ArTime getInfoChanged (int infoType)
 Returns the last time that the specified Info category was changed.
ArPose getLineMaxPose (void)
 Gets the upper right point of the lines.
ArPose getLineMinPose (void)
 Gets the lower left point of the lines.
std::vector< ArLineSegment > * getLines (void)
 Gets the lines.
ArTime getLinesChanged (void)
 Gets the last time the lines were changed.
ArLog::LogLevel getMapChangedLogLevel (void)
 Gets the level we log our map changed callback at.
std::list< ArArgumentBuilder * > * getMapInfo (void)
 Gets the map info strings.
ArTime getMapInfoChanged (void)
 Gets the last time the map info was changed.
std::list< ArMapObject * > * getMapObjects (void)
 Gets the map objects.
ArTime getMapObjectsChanged (void)
 Gets the last time the map objects were changed.
ArPose getMaxPose (void)
 Gets the upper right point of the points.
ArPose getMinPose (void)
 Gets the lower left point of the points.
int getNumLines (void)
 Gets the number of lines.
int getNumPoints (void)
 Gets the number of points.
std::vector< ArPose > * getPoints (void)
 Gets the map points.
ArTime getPointsChanged (void)
 Gets the last time the points were changed.
int getResolution (void)
 Gets the resolution (-1 if none specified).
bool isLoadingDataStarted ()
bool isLoadingLinesAndDataStarted ()
void loadDataPoint (double x, double y)
 Adds the specified data point to the loading points.
void loadLineSegment (double x1, double y1, double x2, double y2)
 Adds the specified line segment to the loading lines.
int lock ()
 Lock the map instance.
void mapChanged (void)
 Function that will call the map changed CBs if needed.
bool parseLine (char *line)
 Parses a map line.
void parsingComplete (void)
 Says that the parsing by lines is done and to use the parsed data.
bool readDataPoint (char *line)
 Reads a data point from the given line, and adds it to the loading points.
bool readFile (const char *fileName, char *errorBuffer=NULL, size_t errorBufferLen=0)
 Reads a map.
bool readLineSegment (char *line)
 Reads a line segment from the given line, and adds it to the loading lines.
void remMapChangedCB (ArFunctor *functor)
 Removes a callback called when the map is changed.
void setBaseDirectory (const char *baseDirectory)
 Sets the base directory.
void setIgnoreEmptyFileName (bool ignore)
 Sets whether we ignore empty file names or fail if we encounter one.
bool setInfo (int infoType, const std::list< ArArgumentBuilder * > *infoList)
 Sets the contents of the specified Info category.
void setLines (const std::vector< ArLineSegment > *lines)
 Sets the lines (copies those passed in).
void setMapChangedLogLevel (ArLog::LogLevel level)
 Sets the level we log our map changed callback at.
void setMapInfo (const std::list< ArArgumentBuilder * > *mapInfo)
 Sets the map info (copies those passed in).
void setMapObjects (const std::list< ArMapObject * > *mapObjects)
 Sets the map objects (copies those passed in).
void setPoints (const std::vector< ArPose > *points)
 Sets the points (copies those passed in).
void setResolution (int resolution)
int tryLock ()
 Try to lock the map instance without blocking.
int unlock ()
 Unlock the map instance.
bool writeFile (const char *fileName)
 Write out a map file.
void writeLinesToFunctor (ArFunctor2< int, std::vector< ArLineSegment > * > *functor)
 Writes the map line segments to a functor.
void writeObjectsToFunctor (ArFunctor1< const char * > *functor, const char *endOfLineChars)
 Writes the map header information and objects to a text-based functor.
void writePointsToFunctor (ArFunctor2< int, std::vector< ArPose > * > *functor)
 Writes the map data points to a functor.
void writeToFunctor (ArFunctor1< const char * > *functor, const char *endOfLineChars)
 Writes all of the map to a functor instead of a to a file.
virtual ~ArMap (void)
 Destructor.

Protected Member Functions

virtual const char * getInfoName (int infoType)
 Returns the name of the specified Info category (i.e. the "xInfo:" tag at the beginning of the line).
bool handle2DMap (ArArgumentBuilder *arg)
bool handleData (ArArgumentBuilder *arg)
bool handleInfo (ArArgumentBuilder *arg, int info)
bool handleLine (ArArgumentBuilder *arg)
bool handleLineMaxPos (ArArgumentBuilder *arg)
bool handleLineMinPos (ArArgumentBuilder *arg)
bool handleLines (ArArgumentBuilder *arg)
bool handleMapInfo (ArArgumentBuilder *arg)
bool handleMapObject (ArArgumentBuilder *arg)
bool handleMaxPos (ArArgumentBuilder *arg)
bool handleMinPos (ArArgumentBuilder *arg)
bool handleNumLines (ArArgumentBuilder *arg)
bool handleNumPoints (ArArgumentBuilder *arg)
bool handlePoint (ArArgumentBuilder *arg)
bool handleResolution (ArArgumentBuilder *arg)
bool processFile (char *errorBuffer, size_t errorBufferLen)
bool reset (void)

Protected Attributes

ArRetFunctor1C< bool, ArMap,
ArArgumentBuilder * > 
my2DMapCB
std::string myBaseDirectory
char myConfigMapName [512]
std::string myConfigParam
bool myConfigProcessedBefore
ArRetFunctor1C< bool, ArMap,
ArArgumentBuilder * > 
myDataCB
std::string myFileName
bool myIgnoreEmptyFileName
std::list< ArArgumentBuilder * > * myInfoArray
ArRetFunctor2C< bool, ArMap,
ArArgumentBuilder *, int > ** 
myInfoCBArray
ArTimemyInfoChangedArray
ArRetFunctor1C< bool, ArMap,
ArArgumentBuilder * > 
myLineCB
ArPose myLineMax
ArRetFunctor1C< bool, ArMap,
ArArgumentBuilder * > 
myLineMaxPosCB
ArPose myLineMin
ArRetFunctor1C< bool, ArMap,
ArArgumentBuilder * > 
myLineMinPosCB
std::vector< ArLineSegmentmyLines
ArRetFunctor1C< bool, ArMap,
ArArgumentBuilder * > 
myLinesCB
ArTime myLinesChanged
bool myLoadingDataStarted
bool myLoadingGot2DMap
bool myLoadingGotLineMaxPos
bool myLoadingGotLineMinPos
bool myLoadingGotMaxPos
bool myLoadingGotMinPos
std::list< ArArgumentBuilder * > * myLoadingInfoArray
ArPose myLoadingLineMax
ArPose myLoadingLineMaxFromFile
ArPose myLoadingLineMin
ArPose myLoadingLineMinFromFile
std::vector< ArLineSegmentmyLoadingLines
bool myLoadingLinesAndDataStarted
int myLoadingLinesRead
std::list< ArArgumentBuilder * > myLoadingMapInfo
std::list< ArMapObject * > myLoadingMapObjects
ArPose myLoadingMax
ArPose myLoadingMaxFromFile
ArPose myLoadingMin
ArPose myLoadingMinFromFile
int myLoadingNumLines
int myLoadingNumPoints
ArFileParsermyLoadingParser
std::vector< ArPosemyLoadingPoints
int myLoadingPointsRead
int myLoadingResolution
std::list< ArFunctor * > myMapChangedCBList
ArTimemyMapChangedInfoArray
ArLog::LogLevel myMapChangedLogLevel
ArTime myMapChangedMapInfo
ArTime myMapChangedMapObjects
ArTime myMapChangedPoints
std::list< ArArgumentBuilder * > myMapInfo
ArRetFunctor1C< bool, ArMap,
ArArgumentBuilder * > 
myMapInfoCB
ArTime myMapInfoChanged
ArRetFunctor1C< bool, ArMap,
ArArgumentBuilder * > 
myMapObjectCB
std::list< ArMapObject * > myMapObjects
ArTime myMapObjectsChanged
ArPose myMax
ArRetFunctor1C< bool, ArMap,
ArArgumentBuilder * > 
myMaxPosCB
ArPose myMin
ArRetFunctor1C< bool, ArMap,
ArArgumentBuilder * > 
myMinPosCB
ArMutex myMutex
int myNumInfos
 Number of different Info categories available in this map.
int myNumLines
ArRetFunctor1C< bool, ArMap,
ArArgumentBuilder * > 
myNumLinesCB
int myNumPoints
ArRetFunctor1C< bool, ArMap,
ArArgumentBuilder * > 
myNumPointsCB
ArRetFunctor1C< bool, ArMap,
ArArgumentBuilder * > 
myPointCB
std::vector< ArPosemyPoints
ArTime myPointsChanged
ArRetFunctor2C< bool, ArMap,
char *, size_t > 
myProcessFileCB
stat myReadFileStat
int myResolution
ArRetFunctor1C< bool, ArMap,
ArArgumentBuilder * > 
myResolutionCB

Static Protected Attributes

static const char * ourInfoNames [INFO_COUNT]
 Array of names for the standard Info categories; see InfoType.


Detailed Description

This is a class for maps made with ScanStudio and Mapper3.

ArMap encapsulates the data contained in a .map file. It provides methods to read and write a .map file, and to obtain and modify the contents of the map. In addition, the application may install callbacks on the map to be notified when its contents are modified.

Aria maps contain the following types of data:

See below for the exact format of the actual .map file.

Thread Issues

The ArMap class is not inherently thread-safe. It has a lock and unlock associated with it, which the application must call before and after calls to get and set the data (e.g. getMapObjects(), getPoints()... setMapObjects(), setPoints()...).

If you are going to use setMapObjects(), setPoints(), setLines(), or setMapInfo(), then you should lock() the map beforehand, call the methods, then call mapChanged() to invoke the callbacks, and then finally unlock() the map when done. Note that mapChanged() will only invoke the callbacks if the data has actually changed.

The readFile() and writeFile() methods do automatically lock the map while they read and write.

Map Objects

Certain types of objects are always predefined for ArMaps. These include Goal, GoalWithHeading, Dock, ForbiddenLine, ForbiddenArea, and RobotHome.

Each rectangle object may have an associated angle of rotation that is currently stored in the ArMapObject::getPose().getTh() value. If this value is non-zero, then the actual global coordinates of the rectangle's polygon must be calculated from the "from-to" values. The following formula should be used (with improvements in efficiency perhaps):

   double degreesToRadians(double degrees) { 
      return degrees * (3.1415926535 / 180.0); 
   }
   int round(double d) { 
      if (d >= 0.0) {
         return int(d + 0.5);
		}
		else {
		    return int( d - ((int)d-1) + 0.5 ) + ((int)d-1); 
      }
   }

   // Computation:
   double rotation = mapObject->getPose().getTh();
   ArPose minPt = mapObject->getFromPose();
   ArPose maxPt = mapObject->getToPose();

   double radians = ArQ::degreesToRadians(rotation);
   double c = ::cos(radians);
   double s = ::sin(radians);

   ArPose globalPoints[4];
   globalPoints[0] = ArPose(minPt.getX(), minPt.getY());
   globalPoints[1] = ArPose(maxPt.getX(), minPt.getY());
   globalPoints[2] = ArPose(maxPt.getX(), maxPt.getY());
   globalPoints[3] = ArPose(minPt.getX(), maxPt.getY());

   for (int i = 0; i < 4; i++) {
      ArPose pt = globalPoints[i];
      globalPoints[i] = ArPose(round((c * pt.getX()) - (s * pt.getY())),
                               round((s * pt.getX()) + (c * pt.getY())));
   }
 

Map Customization

It is possible to add additional types of objects to an ArMap using the MapInfo metadata section. For example, if you wished to program some special behavior that would only occur upon reaching certain goals, you could define a new goal type as follows:

    MapInfo: GoalType Name=SpecialGoal "Label=Special" "Desc=Doing special stuff" Heading=Required Shape=VBars
 
The new goal type will appear be available in Mapper3 in a drop-down menu. Instances in the map will also be displayed by MobileEyes.

Note that if a map defines special GoalType or DockType items, then it must define all of the goal or dock types (including the default "Goal" if desired).

Please read the following information carefully if you plan to use this feature.

Each MapInfo line is of the format:

       MapInfo: <Keyword> ([ParamName=ParmValue] )*
 

The following Keywords are supported:

The available parameters depend on the Keyword. Unless otherwise specified, parameters are optional.

If a parameter value contains a space, then both the parameter name and value must be enclosed within quotes. For example:

      "Label=Normal Goal"
 
Neither the name nor the value can contain the special characters #, ;, , or ".

The following ParamNames are valid for all keywords:

For GoalType, DockType, and LocationType, the following ParamNames are also supported:

In addition, the following ParamName is supported only for GoalTypes: For BoundaryType, the following ParamNames are also supported: For SectorType, the following ParamNames are also supported: Map File Specification

The .map file is an ASCII text file which may be viewed or edited with a text editor (although using Mapper3 is usually more advisable for simple editing).

The format of the file is as follows:

ARMAPFILE       = ("2D-Map\n") (MapHeader) (Metadata)* (MapObjects)* (DataSection)

MapHeader       = HeaderKey ":" WS HeaderVal "\n"
HeaderKey       = MinPos | MaxPos | NumPoints | LineMinPos | LineMaxPos | NumLines | Resolution
HeaderVal       = Integer | Integer WS Integer

Metadata        = MapInfo ":" WS MapInfoVal "\n"
MapInfoVal		= MapInfoKeyword ([ParamName=ParamValue] )*
MapInfoKeyword    (see "Map Customization" above)
ParamName         (see "Map Customization" above)
ParamValue        (see "Map Customization" above)

MapObjects      = Cairn ":" CairnType WS (Pose) WS Nothing WS "ICON" WS Label [CairnTypeSpecificData] "\n"
CairnType       = StringID
Pose            = XPos WS YPos WS Theta
FromPos         = XPos WS YPos
ToPos           = XPos WS YPos
XPos            = Integer
YPos            = Integer
Theta           = Double
Nothing         = ""
Label           = QuotedString

DataSection     = ("LINES\n" (LineLine)*) | ("DATA\n" (PointLine)*)
LineLine        = FromPos WS ToPos "\n"
PointLine       = XPos WS YPos "\n"

Integer         = ["-"](DIGIT +))
StringID        = (ALNUM)(ALNUM*)
QuotedString    = " (ALNUM | WS)* "

DIGIT           = ("0"-"9")
ALNUM           = any 8 bit ASCII character or numeral except " (double quote 
                  mark), #, ; (semi-colon),  (percent), or space, tab, newline, 
				  or any other whitespace or control character.
WS              = (" ")*

Notes:

  1. Currently used StringIDs for CairnType are: (Goal | GoalWithHeading | RobotHome | Dock | ForbiddenLine | ForbiddenArea). In addition, any custom types defined in MapInfo are acceptable.
  2. The following CairnTypeSpecificData is valid for ForbiddenLine, ForbiddenArea, rectangular RobotHome's, and all custom BoundaryType and SectorType's:
           CairnTypeSpecificData = FromPos WS ToPos
        
    These are the coordinates that should generally be used for these objects. For the rectangular (i.e. non-line) objects, the main Pose in the Cairn line contains the rotation; the x and y values are currently undefined.
  3. The other Cairn types have no TypeSpecificData
  4. Theta in CairnData is ignored for Goal, ForbiddenLine, and all custom BoundaryTypes.
  5. The Nothing token in CarinData is not used, and is almost always just an empty quoted string: ""
  6. It can be better to calculate maximum, minimum, and number of points or lines based on the data in the map, if possible, rather than relying on the metadata header.

Definition at line 280 of file ArMap.h.


Member Enumeration Documentation

anonymous enum
 

Enumeration values:
INFO_COUNT  Number of standard Info categories.

Definition at line 293 of file ArMap.h.

enum ArMap::InfoType
 

List of the standard Info categories defined for the map.

Enumeration values:
LAST_INFO  Last value in the enumeration.

Definition at line 285 of file ArMap.h.


Constructor & Destructor Documentation

ArMap::ArMap const char *  baseDirectory = "./",
bool  addToGlobalConfig = true,
const char *  configSection = "Files",
const char *  configParam = "Map",
const char *  configDesc = "Map of the environment we'll use to navigate",
bool  ignoreEmptyFileName = true
 

Constructor.

myRouteInfoCB(this, &ArMap::handleRouteInfo),

Definition at line 49 of file ArMap.cpp.

References ArConfig::addParam(), ArConfig::addProcessFileWithErrorCB(), Aria::getConfig(), myNumInfos, setBaseDirectory(), and ArFunctor::setName().


Member Function Documentation

void ArMap::addMapChangedCB ArFunctor functor,
ArListPos::Pos  position = ArListPos::LAST
 

Adds a callback called when the map is changed.

Adds a read callback that is called when the map is read in, the map is locked when this callback happens so you don't need to worry about that.

Definition at line 196 of file ArMap.cpp.

References ArLog::log().

Referenced by ArForbiddenRangeDevice::setRobot().

ArMapObject * ArMap::findMapObject const char *  name,
const char *  type = NULL
 

Gets a map object of given name and type if it exists.

Parameters:
name The name of the object to try to find, NULL means find any name
type The type of object to try to find... NULL means find any type

Definition at line 1351 of file ArMap.cpp.

References getMapObjects(), ArMapObject::getName(), and ArMapObject::getType().

std::list< ArArgumentBuilder * > * ArMap::getInfo int  infoType  ) 
 

Gets the strings for the specified Info category.

Parameters:
infoType the int ID of the Info category; must be >= 0 and less than numInfos
Returns:
std::list<ArArgumentBuilder *> * a pointer to the Info list; NULL if infoType was invalid

Definition at line 181 of file ArMap.cpp.

References myNumInfos.

ArTime ArMap::getInfoChanged int  infoType  ) 
 

Returns the last time that the specified Info category was changed.

Parameters:
infoType the int ID of the Info category; must be >= 0 and < numInfos
Returns:
ArTime the time that the Info category was last changed; returns default time (1/1/1970) if infoType is invalid

Definition at line 617 of file ArMap.cpp.

References ArTime::setMSec(), and ArTime::setSec().

const char * ArMap::getInfoName int  infoType  )  [protected, virtual]
 

Returns the name of the specified Info category (i.e. the "xInfo:" tag at the beginning of the line).

If subclasses define additional Info categories, then they must override this method.

Parameters:
infoType the int ID of the Info category
Returns:
const char * the name of the specified Info category; or NULL if not found

Definition at line 1378 of file ArMap.cpp.

References INFO_COUNT, and ourInfoNames.

bool ArMap::handleData ArArgumentBuilder arg  )  [protected]
 

bool ArMap::handleRouteInfo(ArArgumentBuilder *arg) { ArArgumentBuilder *routeInfo = NULL; routeInfo = new ArArgumentBuilder(*arg); myLoadingRouteInfo.push_back(routeInfo); return true; }

Definition at line 501 of file ArMap.cpp.

References ArLog::log().

bool ArMap::isLoadingDataStarted  )  [inline]
 

This value returns true once the DATA tag has been reached. The rest of the map contains data points.

Definition at line 443 of file ArMap.h.

bool ArMap::isLoadingLinesAndDataStarted  )  [inline]
 

This value returns true once the LINES tag has been reached. The rest of the map contains data points.

Definition at line 450 of file ArMap.h.

void ArMap::parsingComplete void   ) 
 

Says that the parsing by lines is done and to use the parsed data.

If you've been giving the map lines to parse with parseLine and you are finished then you should call this function call to move all of that data from the loading zone into the main variables.

Definition at line 1075 of file ArMap.cpp.

References lock(), ArLog::log(), mapChanged(), setInfo(), setLines(), setMapInfo(), setMapObjects(), setPoints(), and unlock().

bool ArMap::readFile const char *  fileName,
char *  errorBuffer = NULL,
size_t  errorBufferLen = 0
 

Reads a map.

Parameters:
fileName the name of the file to read
errorBuffer this is mainly for the config stuff, saves errors here (you can just use the default NULL)
errorBufferLen length of the error buffer

Definition at line 842 of file ArMap.cpp.

References lock(), ArLog::log(), mapChanged(), readDataPoint(), readLineSegment(), setInfo(), setLines(), setMapInfo(), setMapObjects(), setPoints(), and unlock().

bool ArMap::setInfo int  infoType,
const std::list< ArArgumentBuilder * > *  infoList
 

Sets the contents of the specified Info category.

Parameters:
infoType the int ID of the Info category to be set; must be >= 0 and < numInfos;
infoList the std::list<ArArgumentBuilder *> * that defines the Info category's contents; NULL to clear the Info
Returns:
bool set to true if the contents were successfully set; false, if infoType was invalid

Definition at line 779 of file ArMap.cpp.

References ArUtil::deleteSet(), and ArTime::setToNow().

Referenced by parsingComplete(), and readFile().

void ArMap::setLines const std::vector< ArLineSegment > *  lines  ) 
 

Sets the lines (copies those passed in).

Deletes and clears the old lines (and the info about our lines) and then makes a copy of the ones passed in.

Parameters:
inesthe lines to copy, if NULL just clears the ones we had

Definition at line 705 of file ArMap.cpp.

References ArPose::getX(), ArLineSegment::getX1(), ArLineSegment::getX2(), ArPose::getY(), ArLineSegment::getY1(), ArLineSegment::getY2(), ArTime::setToNow(), ArPose::setX(), and ArPose::setY().

Referenced by parsingComplete(), and readFile().

void ArMap::setMapInfo const std::list< ArArgumentBuilder * > *  mapInfo  ) 
 

Sets the map info (copies those passed in).

Deletes and clears the old mapInfo and then makes a copy of the ones passed in.

Parameters:
mapInfo the mapInfo to copy, if NULL just deletes the ones we had

Definition at line 765 of file ArMap.cpp.

References ArUtil::deleteSet(), and ArTime::setToNow().

Referenced by parsingComplete(), and readFile().

void ArMap::setMapObjects const std::list< ArMapObject * > *  mapObjects  ) 
 

Sets the map objects (copies those passed in).

Deletes and clears the old map objects and then makes a copy of the ones passed in.

Parameters:
mapObjects the map objects to copy, if NULL just deletes the ones we had

Definition at line 637 of file ArMap.cpp.

References ArUtil::deleteSet(), and ArTime::setToNow().

Referenced by parsingComplete(), and readFile().

void ArMap::setPoints const std::vector< ArPose > *  points  ) 
 

Sets the points (copies those passed in).

Deletes and clears the old points (and the info about our points) and then makes a copy of the ones passed in.

Parameters:
points the points to copy, if NULL just clears the ones we had

Definition at line 657 of file ArMap.cpp.

References ArPose::getX(), ArPose::getY(), ArTime::setToNow(), ArPose::setX(), and ArPose::setY().

Referenced by parsingComplete(), and readFile().

bool ArMap::writeFile const char *  fileName  ) 
 

Write out a map file.

Writes a file out... The map is locked while the write happens.

Parameters:
fileName the fileName to write out
overwrite if true then it'll overwrite, otherwise it'll just fail

Definition at line 1304 of file ArMap.cpp.

References lock(), ArLog::log(), unlock(), and writeToFunctor().

void ArMap::writeLinesToFunctor ArFunctor2< int, std::vector< ArLineSegment > * > *  functor  ) 
 

Writes the map line segments to a functor.

A pointer to the entire line segment vector is passed directly to the modify the vector's contents.

Definition at line 1290 of file ArMap.cpp.

void ArMap::writeObjectsToFunctor ArFunctor1< const char * > *  functor,
const char *  endOfLineChars
 

Writes the map header information and objects to a text-based functor.

This method writes everything up to and including the DATA tag to the given functor. The data points are not written.

Definition at line 1189 of file ArMap.cpp.

References ArUtil::functorPrintf(), ArMapObject::getFileName(), ArMapObject::getFromPose(), ArMapObject::getIconName(), ArMapObject::getName(), ArMapObject::getPose(), ArPose::getTh(), ArMapObject::getToPose(), ArMapObject::getType(), ArPose::getX(), ArPose::getY(), ArMapObject::hasFromTo(), and ArLog::log().

Referenced by writeToFunctor().

void ArMap::writePointsToFunctor ArFunctor2< int, std::vector< ArPose > * > *  functor  ) 
 

Writes the map data points to a functor.

A pointer to the entire data point vector is passed directly to the functor in order to improve performance. The functor should not modify the vector's contents.

Definition at line 1284 of file ArMap.cpp.

void ArMap::writeToFunctor ArFunctor1< const char * > *  functor,
const char *  endOfLineChars
 

Writes all of the map to a functor instead of a to a file.

This function calls the functor with each line of the map, the lines do not have any
or characters on them

Definition at line 1146 of file ArMap.cpp.

References ArUtil::functorPrintf(), and writeObjectsToFunctor().

Referenced by writeFile().


Member Data Documentation

const char * ArMap::ourInfoNames [static, protected]
 

Initial value:

 
{
        "TaskInfo:",
        "RouteInfo:"
}
Array of names for the standard Info categories; see InfoType.

Definition at line 37 of file ArMap.cpp.

Referenced by getInfoName().


The documentation for this class was generated from the following files:
Generated on Wed Oct 19 12:56:49 2005 for Aria by  doxygen 1.4.0