libhomegear-base  0.7
Base library for Homegear and Homegear family modules.
BaseLib::Math::Line Class Reference

Class defining a line. More...

#include <Math.h>

Public Member Functions

 Line ()
 
 Line (const Point2D &a, const Point2D &b)
 
virtual ~Line ()
 
Point2D getA () const
 
void setA (Point2D value)
 
void setA (Point2D &value)
 
Point2D getB () const
 
void setB (Point2D value)
 
void setB (Point2D &value)
 
void closestPointToPoint (const Point2D &p, Point2D &r)
 Finds the closest point on the line to a point. More...
 

Protected Attributes

Point2D _a
 
Point2D _b
 

Detailed Description

Class defining a line.

Constructor & Destructor Documentation

§ Line() [1/2]

BaseLib::Math::Line::Line ( )
inline

§ Line() [2/2]

BaseLib::Math::Line::Line ( const Point2D a,
const Point2D b 
)
inline

§ ~Line()

virtual BaseLib::Math::Line::~Line ( )
inlinevirtual

Member Function Documentation

§ closestPointToPoint()

void BaseLib::Math::Line::closestPointToPoint ( const Point2D p,
Point2D r 
)

Finds the closest point on the line to a point.

Parameters
[in]pThe point to get the closest point on the line for.
[out]rThe point on the line which is closest to p.

§ getA()

Point2D BaseLib::Math::Line::getA ( ) const
inline

§ getB()

Point2D BaseLib::Math::Line::getB ( ) const
inline

§ setA() [1/2]

void BaseLib::Math::Line::setA ( Point2D  value)
inline

§ setA() [2/2]

void BaseLib::Math::Line::setA ( Point2D value)
inline

§ setB() [1/2]

void BaseLib::Math::Line::setB ( Point2D  value)
inline

§ setB() [2/2]

void BaseLib::Math::Line::setB ( Point2D value)
inline

Member Data Documentation

§ _a

Point2D BaseLib::Math::Line::_a
protected

§ _b

Point2D BaseLib::Math::Line::_b
protected

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