Parameterized base class for points. More...
#include <ogdf/basic/geometry.h>
Public Types | |
| using | numberType = NUMBER |
| The type for coordinates of the point. More... | |
Public Member Functions | |
| GenericPoint () | |
| Creates a generic point. More... | |
| GenericPoint (NUMBER x, NUMBER y) | |
Creates a generic point (x,y). More... | |
| GenericPoint (const GenericPoint &p) | |
| Copy constructor. More... | |
| double | angle (GenericPoint q, GenericPoint r) const |
| Compute angle (in radians) between vectors. More... | |
| double | angleDegrees (GenericPoint q, GenericPoint r) const |
| Compute angle (in degrees) between vectors. More... | |
| bool | operator!= (const GenericPoint &p) const |
| Inequality operator. More... | |
| bool | operator< (const GenericPoint &p) |
| GenericPoint & | operator= (const GenericPoint &p) |
| Assignment operator. More... | |
| bool | operator== (const GenericPoint &p) const |
| Equality operator. More... | |
| bool | operator> (const GenericPoint &p) |
Public Attributes | |
| NUMBER | m_x |
| The x-coordinate. More... | |
| NUMBER | m_y |
| The y-coordinate. More... | |
Parameterized base class for points.
This class serves as base class for two-dimensional points with specific coordinate types like integer points (IPoint) and real points (DPoint). The template parameter NUMBER is the type for the coordinates of the point and has to support assignment and equality/inequality operators.
Definition at line 71 of file geometry.h.
| using ogdf::GenericPoint< NUMBER >::numberType = NUMBER |
The type for coordinates of the point.
Definition at line 75 of file geometry.h.
|
inline |
Creates a generic point.
Definition at line 85 of file geometry.h.
|
inline |
Creates a generic point (x,y).
Definition at line 88 of file geometry.h.
|
inline |
Copy constructor.
Definition at line 91 of file geometry.h.
|
inline |
Compute angle (in radians) between vectors.
Definition at line 119 of file geometry.h.
|
inline |
Compute angle (in degrees) between vectors.
Definition at line 144 of file geometry.h.
|
inline |
Inequality operator.
Definition at line 106 of file geometry.h.
|
inline |
Definition at line 110 of file geometry.h.
|
inline |
Assignment operator.
Definition at line 94 of file geometry.h.
|
inline |
Equality operator.
Definition at line 101 of file geometry.h.
|
inline |
Definition at line 114 of file geometry.h.
| NUMBER ogdf::GenericPoint< NUMBER >::m_x |
The x-coordinate.
Definition at line 77 of file geometry.h.
| NUMBER ogdf::GenericPoint< NUMBER >::m_y |
The y-coordinate.
Definition at line 78 of file geometry.h.