#include <GeoTrajectory.h>
Public Member Functions | |
Trajectory (size_t npoints=0, size_t ndimension=0) | |
Default ctor to specify # points and dimension of each point. More... | |
virtual | ~Trajectory () |
Default dtor. More... | |
Trajectory (const std::vector< std::vector< double > > &obj) | |
Alternative ctor (0) using a vector of mere vector point expression. More... | |
Trajectory (const std::vector< geoalgo::Point_t > &obj) | |
Alternative ctor (1) using a vector of point. More... | |
double | Length (size_t start_step=0, size_t end_step=0) const |
The summed-length along all trajectory points. More... | |
bool | IsLonger (double) const |
Check if the trajectory is longer than specified value. More... | |
Vector | Dir (size_t i=0) const |
The direction at a specified trajectory point. More... | |
void | push_back (const Point_t &obj) |
push_back overrie w/ dimensionality check More... | |
Trajectory & | operator+= (const Point_t &rhs) |
void | compat (const Point_t &obj) const |
Dimensionality check function w/ Trajectory. More... | |
void | compat (const Trajectory &obj) const |
Dimensionality check function w/ Point_t. More... | |
template<class T > | |
void | push_back (const T &obj) |
push_back template More... | |
Protected Member Functions | |
Vector | _Dir_ (size_t i) const |
Returns a direction vector at a specified trajectory point w/o size check. More... | |
Friends | |
std::ostream & | operator<< (std::ostream &o, Trajectory const &a) |
Streamer. More... | |
This class represents a trajectory which is an ordered list of Point. It is a friend class w/ geoalgo::Point_t hence it has an access to protected functions that avoids dimensionality sanity checks for speed.
Definition at line 31 of file GeoTrajectory.h.
geoalgo::Trajectory::Trajectory | ( | size_t | npoints = 0 , |
size_t | ndimension = 0 |
||
) |
Default ctor to specify # points and dimension of each point.
Definition at line 8 of file GeoTrajectory.cxx.
|
inlinevirtual |
geoalgo::Trajectory::Trajectory | ( | const std::vector< std::vector< double > > & | obj | ) |
Alternative ctor (0) using a vector of mere vector point expression.
Definition at line 12 of file GeoTrajectory.cxx.
geoalgo::Trajectory::Trajectory | ( | const std::vector< geoalgo::Point_t > & | obj | ) |
Alternative ctor (1) using a vector of point.
Definition at line 18 of file GeoTrajectory.cxx.
|
protected |
Returns a direction vector at a specified trajectory point w/o size check.
Definition at line 104 of file GeoTrajectory.cxx.
void geoalgo::Trajectory::compat | ( | const Point_t & | obj | ) | const |
Dimensionality check function w/ Trajectory.
Definition at line 65 of file GeoTrajectory.cxx.
void geoalgo::Trajectory::compat | ( | const Trajectory & | obj | ) | const |
Dimensionality check function w/ Point_t.
Definition at line 78 of file GeoTrajectory.cxx.
Vector geoalgo::Trajectory::Dir | ( | size_t | i = 0 | ) | const |
The direction at a specified trajectory point.
Definition at line 93 of file GeoTrajectory.cxx.
bool geoalgo::Trajectory::IsLonger | ( | double | ref | ) | const |
Check if the trajectory is longer than specified value.
Definition at line 44 of file GeoTrajectory.cxx.
double geoalgo::Trajectory::Length | ( | size_t | start_step = 0 , |
size_t | end_step = 0 |
||
) | const |
The summed-length along all trajectory points.
Definition at line 24 of file GeoTrajectory.cxx.
|
inline |
Definition at line 59 of file GeoTrajectory.h.
void geoalgo::Trajectory::push_back | ( | const Point_t & | obj | ) |
push_back overrie w/ dimensionality check
Definition at line 59 of file GeoTrajectory.cxx.
|
inline |
push_back template
Definition at line 80 of file GeoTrajectory.h.
|
friend |