Limbo 3.5.4
Loading...
Searching...
No Matches
limbo::geometry::orientation_2d Class Reference

a class denoting orientation of lines More...

#include <Geometry.h>

Public Member Functions

 orientation_2d ()
 constructor
 orientation_2d (orientation_2d_enum const &ori)
 constructor
 orientation_2d (const orientation_2d &ori)
 copy constructor
orientation_2doperator= (const orientation_2d &ori)
 assignment
bool operator== (orientation_2d const &rhs) const
 equality operator
bool operator!= (orientation_2d const &rhs) const
 inequality operator
int to_int () const
 convert orientation to integer
void turn_90 ()
 turn 90 degree
orientation_2d get_perpendicular () const
 get perpendicular orientation
bool valid () const
 check whether the orientation is valid

Protected Attributes

int m_orient
 enum type of orientation in integer representation

Friends

bool operator< (orientation_2d const &ori1, orientation_2d const &ori2)
 less than operator

Detailed Description

a class denoting orientation of lines

Definition at line 92 of file Geometry.h.

Constructor & Destructor Documentation

◆ orientation_2d() [1/3]

limbo::geometry::orientation_2d::orientation_2d ( )
inline

constructor

Definition at line 96 of file Geometry.h.

◆ orientation_2d() [2/3]

limbo::geometry::orientation_2d::orientation_2d ( orientation_2d_enum const & ori)
inline

constructor

Parameters
orienum type of orientation

Definition at line 99 of file Geometry.h.

◆ orientation_2d() [3/3]

limbo::geometry::orientation_2d::orientation_2d ( const orientation_2d & ori)
inline

copy constructor

Parameters
orian orientation_2d object

Definition at line 103 of file Geometry.h.

Member Function Documentation

◆ get_perpendicular()

orientation_2d limbo::geometry::orientation_2d::get_perpendicular ( ) const
inline

get perpendicular orientation

Returns
perpendicular orientation

Definition at line 124 of file Geometry.h.

◆ operator!=()

bool limbo::geometry::orientation_2d::operator!= ( orientation_2d const & rhs) const
inline

inequality operator

Parameters
rhsobject at right hand side
Returns
true if they are inequal

Definition at line 116 of file Geometry.h.

◆ operator=()

orientation_2d & limbo::geometry::orientation_2d::operator= ( const orientation_2d & ori)
inline

assignment

Parameters
orian orientation_2d object
Returns
reference to the object

Definition at line 107 of file Geometry.h.

◆ operator==()

bool limbo::geometry::orientation_2d::operator== ( orientation_2d const & rhs) const
inline

equality operator

Parameters
rhsobject at right hand side
Returns
true if they are equal

Definition at line 112 of file Geometry.h.

◆ to_int()

int limbo::geometry::orientation_2d::to_int ( ) const
inline

convert orientation to integer

Returns
integer representation of the orientation

Definition at line 119 of file Geometry.h.

◆ turn_90()

void limbo::geometry::orientation_2d::turn_90 ( )
inline

turn 90 degree

Definition at line 121 of file Geometry.h.

◆ valid()

bool limbo::geometry::orientation_2d::valid ( ) const
inline

check whether the orientation is valid

Returns
true if it is valid

Definition at line 132 of file Geometry.h.

◆ operator<

bool operator< ( orientation_2d const & ori1,
orientation_2d const & ori2 )
friend

less than operator

Parameters
ori1orientation
ori2orientation
Returns
true if ori1 is less than ori2

Definition at line 137 of file Geometry.h.

Member Data Documentation

◆ m_orient

int limbo::geometry::orientation_2d::m_orient
protected

enum type of orientation in integer representation

Definition at line 140 of file Geometry.h.


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