20 #ifndef HURRICANE_POINT
21 #define HURRICANE_POINT
23 #include "hurricane/DbU.h"
58 public:
Point operator+(
const Point& point)
const;
59 public:
Point operator-(
const Point& point)
const;
66 public:
const DbU::Unit& getX()
const {
return _x;};
67 public:
const DbU::Unit& getY()
const {
return _y;};
69 {
return abs(_x - pt.getX()) + abs(_y - pt.getY()); }
82 public:
string _getTypeName()
const {
return _TName(
"Point"); };
83 public:
string _getString()
const;
84 public: Record* _getRecord()
const;
85 public:
void toJson(JsonWriter*)
const;
90 class JsonPoint :
public JsonObject {
93 public:
static void initialize();
94 public: JsonPoint(
unsigned long);
95 public:
virtual string getTypeName()
const;
96 public:
virtual JsonPoint* clone(
unsigned long)
const;
97 public:
virtual void toData(JsonStack&);
std::int64_t Unit
Definition: DbU.h:67
Point description (API)
Definition: Point.h:32
void setY(DbU::Unit y)
Definition: Point.h:75
bool operator==(const Point &point) const
Point & translate(const DbU::Unit &dx, const DbU::Unit &dy)
Point(const DbU::Unit &x, const DbU::Unit &y)
Point(const Point &point)
bool operator!=(const Point &point) const
void setX(DbU::Unit x)
Definition: Point.h:74
Point & operator=(const Point &point)
The namespace dedicated to Hurricane.
Definition: Generalities.dox:5