OGLplus
(0.59.0)
a C++ wrapper for rendering APIs
eagine
units
unit
si
electric_current.hpp
Go to the documentation of this file.
1
9
#ifndef EAGINE_UNITS_UNIT_SI_ELECTRIC_CURRENT_HPP
10
#define EAGINE_UNITS_UNIT_SI_ELECTRIC_CURRENT_HPP
11
12
#include "
common.hpp
"
13
14
namespace
eagine::units {
15
namespace
base {
16
17
// ampere
18
struct
ampere : unit<electric_current, ampere> {};
19
20
}
// namespace base
21
22
template
<>
23
struct
name_of<base::ampere> {
24
static
constexpr
const
char
mp_str[] =
"ampere"
;
25
};
26
template
<>
27
struct
symbol_of<base::ampere> {
28
static
constexpr
const
char
mp_str[] =
"A"
;
29
};
30
31
// si::base_unit<electric_current>
32
template
<>
33
struct
si::base_unit<base::electric_current> : base::ampere {};
34
35
// kiloampere
36
using
ampere = unit<electric_current, si>;
37
38
// derived
39
using
kiloampere =
40
make_scaled_base_dim_unit_t<base::scaled_unit<scales::kilo, base::ampere>, si>;
41
42
using
milliampere =
43
make_scaled_base_dim_unit_t<base::scaled_unit<scales::milli, base::ampere>, si>;
44
45
}
// namespace eagine::units
46
47
#endif // EAGINE_UNITS_UNIT_SI_ELECTRIC_CURRENT_HPP
common.hpp
Copyright © 2015-2021
Matúš Chochlík
.
<
chochlik -at -gmail.com
>
Documentation generated on Tue Apr 13 2021 by
Doxygen
(version 1.8.17).