PLaSK library
|
Helper which allow to implement base class for aligners which work in one direction. More...
#include <plask/geometry/align.hpp>
Public Member Functions | |
AlignerImpl (double coordinate) | |
Construct new aligner. | |
virtual | ~AlignerImpl () |
virtual double | getAlign (double low, double hi) const =0 |
Get translation for aligned obiect. | |
virtual bool | useBounds () const |
Check if this aligner getAlign use bounds (low and hi parameters) in calculation. | |
double | align (Translation< 3 > &toAlign, const Box3D &childBoundingBox) const |
Set object coordinate in direction of aligner activity. | |
virtual double | align (Translation< 3 > &toAlign) const |
Set object translation in direction of aligner activity. | |
virtual std::string | key (const AxisNames &axis_names) const =0 |
Get aligner name. | |
std::map< std::string, double > | asDict (const AxisNames &axis_names) const |
Get aligner as dictionary. | |
void | writeToXML (XMLElement &dest, const AxisNames &axis_names) const |
Write this aligner to XML. | |
Public Member Functions inherited from plask::Printable | |
virtual void | print (std::ostream &out) const =0 |
Print this to stream out . | |
virtual | ~Printable () |
std::string | str () const |
Get string representation of this using print method. | |
Public Attributes | |
double | coordinate |
Coordinate to which this aligner aligns. | |
Static Public Attributes | |
static const Direction | direction = _direction |
Direction of activity. | |
Helper which allow to implement base class for aligners which work in one direction.
Don't use it directly, use Aligner instead.
_direction | direction of activity |
|
inline |
|
inlinevirtual |
|
inlinevirtual |
|
inline |
|
inline |
|
pure virtual |
Get translation for aligned obiect.
low,hi | aligned object bounds in direction of activity of this aligner |
Implemented in plask::align::details::AlignerCustomImpl< direction, strategy, name_tag >.
|
pure virtual |
Get aligner name.
axis_names | name of axes |
Implemented in plask::align::details::AlignerCustomImpl< direction, strategy, name_tag >, and plask::align::details::PositionAlignerImpl< direction >.
|
inlinevirtual |
Check if this aligner getAlign use bounds (low and hi parameters) in calculation.
true
only if this aligner use bounds, false
if bounds are ignored Reimplemented in plask::align::details::PositionAlignerImpl< direction >.
|
inline |
double plask::align::AlignerImpl< _direction >::coordinate |
|
static |