Public Member Functions | Private Attributes
rail::interactive_world::Surface Class Reference

#include <Surface.h>

List of all members.

Public Member Functions

void addAlias (const std::string &alias)
 Alias adder.
void addPlacementSurface (const PlacementSurface &placement_surface)
 Placement surface adder.
void addPointOfInterest (const PointOfInterest &point_of_interest)
 Point of interest adder.
const std::string & getAlias (const size_t index) const
 Alias value accessor.
const std::vector< std::string > & getAliases () const
 Aliases value accessor.
const std::string & getFrameID () const
 Frame ID value accessor.
double getHeight () const
 Height value accessor.
const std::string & getName () const
 Name value accessor.
size_t getNumAliases () const
 Aliases size accessor.
size_t getNumPlacementSurfaces () const
 Placement surfaces size accessor.
size_t getNumPointsOfInterest () const
 Point of interests size accessor.
const PlacementSurfacegetPlacementSurface (const size_t index) const
 Placement surface value accessor.
const std::vector
< PlacementSurface > & 
getPlacementSurfaces () const
 Placement surfaces value accessor.
const PointOfInterestgetPointOfInterest (const size_t index) const
 Point of interest value accessor.
const std::vector
< PointOfInterest > & 
getPointsOfInterest () const
 Points of interest value accessor.
double getWidth () const
 Width value accessor.
void removeAlias (const size_t index)
 Alias remover.
void removePlacementSurface (const size_t index)
 Placement surface remover.
void removePointOfInterest (const size_t index)
 Point of interest remover.
void setFrameID (const std::string &frame_id)
 Frame ID value mutator.
void setHeight (const double height)
 Height value mutator.
void setName (const std::string &name)
 Name value mutator.
void setWidth (const double width)
 Width value mutator.
 Surface (const std::string &name="", const std::string &frame_id="", const double width=0, const double height=0)
 Create a new Surface.

Private Attributes

std::vector< std::string > aliases_
std::string frame_id_
double height_
std::string name_
std::vector< PlacementSurfaceplacement_surfaces_
std::vector< PointOfInterestpois_
double width_

Detailed Description

Definition at line 30 of file Surface.h.


Constructor & Destructor Documentation

Surface::Surface ( const std::string &  name = "",
const std::string &  frame_id = "",
const double  width = 0,
const double  height = 0 
)

Create a new Surface.

Create a new Surface with the given name and frame ID. POI and placement surface lists are empty.

Parameters:
nameThe name of the surface (defaults to the empty string).
frame_idThe frame ID of the surface (defaults to the empty string).
widthThe width of the surface along the X axis (defaults to 0).
heightThe height of the surface along the Y axis (defaults to 0).

Definition at line 17 of file Surface.cpp.


Member Function Documentation

void Surface::addAlias ( const std::string &  alias)

Alias adder.

Add the alias to this Surface.

Parameters:
aliasThe new alias to add.

Definition at line 165 of file Surface.cpp.

void Surface::addPlacementSurface ( const PlacementSurface placement_surface)

Placement surface adder.

Add the placement surface to this Surface.

Parameters:
placement_surfaceThe new placement surface to add.

Definition at line 87 of file Surface.cpp.

void Surface::addPointOfInterest ( const PointOfInterest point_of_interest)

Point of interest adder.

Add the Point of interest to this Surface.

Parameters:
point_of_interestThe new point of interest to add.

Definition at line 126 of file Surface.cpp.

const std::string & Surface::getAlias ( const size_t  index) const

Alias value accessor.

Get the alias of this Surface at the given index.

Parameters:
iThe index of the alias to get.
Returns:
The alias at the given index.
Exceptions:
std::out_of_rangeThrown if the alias at the given index does not exist.

Definition at line 153 of file Surface.cpp.

const std::vector< std::string > & Surface::getAliases ( ) const

Aliases value accessor.

Get the aliases of this Surface.

Returns:
The aliases of this surfaces.

Definition at line 143 of file Surface.cpp.

const string & Surface::getFrameID ( ) const

Frame ID value accessor.

Get the frame ID value of this Surface.

Returns:
The frame ID value.

Definition at line 34 of file Surface.cpp.

double Surface::getHeight ( ) const

Height value accessor.

Get the height value of this Surface.

Returns:
The height value.

Definition at line 54 of file Surface.cpp.

const string & Surface::getName ( ) const

Name value accessor.

Get the name value of this Surface.

Returns:
The name value.

Definition at line 24 of file Surface.cpp.

size_t Surface::getNumAliases ( ) const

Aliases size accessor.

Get the number of aliases of this Surface.

Returns:
The number of aliases of this Surface.

Definition at line 148 of file Surface.cpp.

Placement surfaces size accessor.

Get the number of placement surfaces of this Surface.

Returns:
The number of placement surfaces of this Surface.

Definition at line 70 of file Surface.cpp.

Point of interests size accessor.

Get the number of points of interest of this Surface.

Returns:
The number of points of interest of this Surface.

Definition at line 109 of file Surface.cpp.

const PlacementSurface & Surface::getPlacementSurface ( const size_t  index) const

Placement surface value accessor.

Get the placement surface of this Surface at the given index.

Parameters:
iThe index of the PlacementSurface to get.
Returns:
The placement surface at the given index.
Exceptions:
std::out_of_rangeThrown if the placement surface at the given index does not exist.

Definition at line 75 of file Surface.cpp.

const vector< PlacementSurface > & Surface::getPlacementSurfaces ( ) const

Placement surfaces value accessor.

Get the placement surfaces of this Surface.

Returns:
The placement surfaces.

Definition at line 65 of file Surface.cpp.

const PointOfInterest & Surface::getPointOfInterest ( const size_t  index) const

Point of interest value accessor.

Get the Point of interest of this Surface at the given index.

Parameters:
iThe index of the point of interest to get.
Returns:
The point of interest at the given index.
Exceptions:
std::out_of_rangeThrown if the Point of interest at the given index does not exist.

Definition at line 114 of file Surface.cpp.

const std::vector< PointOfInterest > & Surface::getPointsOfInterest ( ) const

Points of interest value accessor.

Get the points of interest of this Surface.

Returns:
The points of interest.

Definition at line 104 of file Surface.cpp.

double Surface::getWidth ( ) const

Width value accessor.

Get the width value of this Surface.

Returns:
The width value.

Definition at line 44 of file Surface.cpp.

void Surface::removeAlias ( const size_t  index)

Alias remover.

Remove the alias at the given index. An invalid index results in no effect.

Parameters:
iThe index of the alias to remove.
Exceptions:
std::out_of_rangeThrown if the alias at the given index does not exist.

Definition at line 170 of file Surface.cpp.

void Surface::removePlacementSurface ( const size_t  index)

Placement surface remover.

Remove the placement surface at the given index. An invalid index results in no effect.

Parameters:
iThe index of the placement surface to remove.
Exceptions:
std::out_of_rangeThrown if the placement surface at the given index does not exist.

Definition at line 92 of file Surface.cpp.

void Surface::removePointOfInterest ( const size_t  index)

Point of interest remover.

Remove the point of interest at the given index. An invalid index results in no effect.

Parameters:
iThe index of the point of interest to remove.
Exceptions:
std::out_of_rangeThrown if the point of interest at the given index does not exist.

Definition at line 131 of file Surface.cpp.

void Surface::setFrameID ( const std::string &  frame_id)

Frame ID value mutator.

Set the frame ID value of this Surface.

Parameters:
frame_idThe new frame ID value.

Definition at line 39 of file Surface.cpp.

void Surface::setHeight ( const double  height)

Height value mutator.

Set the height value of this Surface.

Parameters:
heightThe new height value.

Definition at line 60 of file Surface.cpp.

void Surface::setName ( const std::string &  name)

Name value mutator.

Set the name value of this Surface.

Parameters:
nameThe new name value.

Definition at line 29 of file Surface.cpp.

void Surface::setWidth ( const double  width)

Width value mutator.

Set the width value of this Surface.

Parameters:
widthThe new width value.

Definition at line 49 of file Surface.cpp.


Member Data Documentation

std::vector<std::string> rail::interactive_world::Surface::aliases_ [private]

List of name aliases.

Definition at line 268 of file Surface.h.

Definition at line 264 of file Surface.h.

Definition at line 266 of file Surface.h.

Name of the surface and frame ID.

Definition at line 264 of file Surface.h.

List of placement surfaces.

Definition at line 270 of file Surface.h.

List of POIs.

Definition at line 272 of file Surface.h.

Size of the surface.

Definition at line 266 of file Surface.h.


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


interactive_world_tools
Author(s): Russell Toris
autogenerated on Thu Jun 6 2019 21:34:15