72 lines
1.6 KiB
C++
72 lines
1.6 KiB
C++
#ifndef _OWLPS_POSITIONING_REFERENCEPOINT_HH_
|
|
#define _OWLPS_POSITIONING_REFERENCEPOINT_HH_
|
|
|
|
class CalibrationMeasurement ;
|
|
|
|
#include "point3d.hh"
|
|
|
|
#include <vector>
|
|
#include <ostream>
|
|
|
|
class ReferencePoint: public Point3D
|
|
{
|
|
protected:
|
|
std::vector<CalibrationMeasurement*> measurements ;
|
|
|
|
public:
|
|
ReferencePoint(const float &_x = 0, const float &_y = 0, const float &_z = 0):
|
|
Point3D(_x, _y, _z) {}
|
|
ReferencePoint(const Point3D &p): Point3D(p) {}
|
|
ReferencePoint(const ReferencePoint &rp):
|
|
Point3D(rp), measurements(rp.measurements) {}
|
|
|
|
~ReferencePoint() ;
|
|
|
|
std::vector<CalibrationMeasurement*> get_measurements() const ;
|
|
|
|
void add_measurement(const CalibrationMeasurement *cm) ;
|
|
// float get_ss_square_distance(const vector<CalibrationMeasurement> &m) const ;
|
|
// bool get_power_for_ap(const string &ap_mac, float *p) const ;
|
|
|
|
ReferencePoint operator=(const ReferencePoint &rp) ;
|
|
bool operator==(const ReferencePoint &rp) const ;
|
|
bool operator!=(const ReferencePoint &rp) const ;
|
|
|
|
friend std::ostream &operator<<(std::ostream &os, const ReferencePoint &rp) ;
|
|
} ;
|
|
|
|
|
|
|
|
/*** Accesseurs lecture ***/
|
|
|
|
|
|
inline
|
|
std::vector<CalibrationMeasurement*> ReferencePoint::get_measurements() const
|
|
{
|
|
return measurements ;
|
|
}
|
|
|
|
|
|
|
|
/*** Accesseurs écriture ***/
|
|
|
|
|
|
inline void ReferencePoint::add_measurement(const CalibrationMeasurement *cm)
|
|
{
|
|
measurements.push_back((CalibrationMeasurement *) cm) ;
|
|
}
|
|
|
|
|
|
|
|
/*** Opérateurs ***/
|
|
|
|
|
|
inline bool ReferencePoint::operator!=(const ReferencePoint &rp) const
|
|
{
|
|
return !(*this == rp) ;
|
|
}
|
|
|
|
|
|
|
|
#endif // _OWLPS_POSITIONING_REFERENCEPOINT_HH_
|