memgraph/poc/kdtree/point.hpp
Mislav Bradac 0588de76bb Move unused datastructures to poc
Reviewers: buda

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D526
2017-07-10 12:03:11 +02:00

27 lines
495 B
C++

#pragma once
#include <ostream>
namespace kd {
template <class T>
class Point {
public:
Point(T latitude, T longitude) : latitude(latitude), longitude(longitude) {}
// latitude
// y
// ^
// |
// 0---> x longitude
T latitude;
T longitude;
/// nice stream formatting with the standard << operator
friend std::ostream& operator<<(std::ostream& stream, const Point& p) {
return stream << "(lat: " << p.latitude << ", lng: " << p.longitude << ')';
}
};
}