~sil2100/location-service/gps-arm64

« back to all changes in this revision

Viewing changes to include/location_service/com/ubuntu/location/units/units.h

  • Committer: Thomas Voß
  • Date: 2013-05-28 14:20:45 UTC
  • Revision ID: thomas.voss@canonical.com-20130528142045-kq5umqdmm4o53vwk
Initial push.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#ifndef LOCATION_SERVICE_COM_UBUNTU_LOCATION_UNITS_UNITS_H_
 
2
#define LOCATION_SERVICE_COM_UBUNTU_LOCATION_UNITS_UNITS_H_
 
3
 
 
4
#include <boost/units/cmath.hpp>
 
5
#include <boost/units/io.hpp>
 
6
#include <boost/units/quantity.hpp>
 
7
#include <boost/units/systems/angle/degrees.hpp>
 
8
#include <boost/units/systems/angle/gradians.hpp>
 
9
#include <boost/units/systems/si.hpp>
 
10
#include <boost/units/systems/si/prefixes.hpp>
 
11
 
 
12
namespace com
 
13
{
 
14
namespace ubuntu
 
15
{
 
16
namespace location
 
17
{
 
18
namespace units
 
19
{
 
20
typedef boost::units::degree::plane_angle PlaneAngle;
 
21
static const PlaneAngle Degree;
 
22
static const PlaneAngle Degrees;
 
23
typedef boost::units::gradian::plane_angle Gradians;
 
24
 
 
25
typedef boost::units::si::length Length;
 
26
static const Length Meter;
 
27
static const Length Meters;
 
28
 
 
29
using boost::units::si::kilo;
 
30
 
 
31
typedef boost::units::si::velocity Velocity;
 
32
static const Velocity MeterPerSecond;
 
33
static const Velocity MetersPerSecond;
 
34
 
 
35
template<typename Unit>
 
36
using Quantity = boost::units::quantity<Unit, double>;
 
37
 
 
38
typedef boost::units::si::dimensionless Dimensionless;
 
39
 
 
40
using boost::units::sin;
 
41
using boost::units::cos;
 
42
using boost::units::atan2;
 
43
}
 
44
}
 
45
}
 
46
}
 
47
 
 
48
#endif // LOCATION_SERVICE_COM_UBUNTU_LOCATION_UNITS_UNITS_H_
 
49