Control Libraries 6.3.4
|
Public Member Functions | |
constexpr | Distance (long double n=0.0) |
Constructor with a value in meter. More... | |
constexpr | Distance (const Distance &dist) |
Copy constructor from another distance. More... | |
constexpr long double | get_value () const |
Getter of the value attribute. More... | |
constexpr Distance & | operator- () |
Overload the - operator. More... | |
constexpr Distance & | operator+= (const Distance &rhs) |
Overload the += operator. More... | |
constexpr Distance | operator+ (const Distance &rhs) const |
Overload the + operator. More... | |
constexpr Distance & | operator-= (const Distance &rhs) |
Overload the -= operator. More... | |
constexpr Distance | operator- (const Distance &rhs) const |
Overload the - operator. More... | |
constexpr Distance & | operator*= (double lambda) |
Overload the *= operator with a scalar. More... | |
constexpr Distance | operator* (double lambda) const |
Overload the * operator with a scalar. More... | |
constexpr Distance & | operator/= (double lambda) |
Overload the /= operator with a scalar. More... | |
constexpr Distance | operator/ (double lambda) const |
Overload the / operator with a scalar. More... | |
constexpr bool | operator== (const Distance &rhs) const |
Overload the == operator. More... | |
constexpr bool | operator!= (const Distance &rhs) const |
Overload the != operator. More... | |
constexpr bool | operator> (const Distance &rhs) const |
Overload the > operator. More... | |
constexpr bool | operator>= (const Distance &rhs) const |
Overload the > operator. More... | |
constexpr bool | operator< (const Distance &rhs) const |
Overload the < operator. More... | |
constexpr bool | operator<= (const Distance &rhs) const |
Overload the < operator. More... | |
Friends | |
constexpr double | operator/ (const Distance &lhs, const Distance &rhs) |
Overload the / operator between two distances. More... | |
constexpr Distance | operator* (double lambda, const Distance &rhs) |
Overload the / operator with a scalar on the left side. More... | |
constexpr Distance | literals::operator""_m (long double n) |
Literal operator to create a Distance in meter. More... | |
constexpr Distance | literals::operator""_km (long double n) |
Literal operator to create a Distance in kilometer. More... | |
constexpr Distance | literals::operator""_dm (long double n) |
Literal operator to create a Distance in decimeter. More... | |
constexpr Distance | literals::operator""_cm (long double n) |
Literal operator to create a Distance in centimeter. More... | |
constexpr Distance | literals::operator""_mm (long double n) |
Literal operator to create a Distance in millimeter. More... | |
Definition at line 45 of file Distance.hpp.
|
constexpr |
Constructor with a value in meter.
n | the value in meter |
Definition at line 223 of file Distance.hpp.
|
constexpr |
Copy constructor from another distance.
dist | the distance to copy |
Definition at line 226 of file Distance.hpp.
|
constexpr |
Getter of the value attribute.
Definition at line 229 of file Distance.hpp.
|
constexpr |
Overload the != operator.
rhs | the other Distance to check inequality with |
Definition at line 286 of file Distance.hpp.
|
constexpr |
Overload the * operator with a scalar.
lambda | the scalar to multiply with |
Definition at line 265 of file Distance.hpp.
|
constexpr |
Overload the *= operator with a scalar.
lambda | the scalar to multiply with |
Definition at line 260 of file Distance.hpp.
|
constexpr |
|
constexpr |
Overload the += operator.
rhs | Distance to add |
Definition at line 238 of file Distance.hpp.
|
constexpr |
Overload the - operator.
Definition at line 233 of file Distance.hpp.
|
constexpr |
Overload the - operator.
rhs | Distance to subtract |
Definition at line 254 of file Distance.hpp.
|
constexpr |
Overload the -= operator.
rhs | Distance to subtract |
Definition at line 249 of file Distance.hpp.
|
constexpr |
Overload the / operator with a scalar.
lambda | the scalar to divide by |
Definition at line 276 of file Distance.hpp.
|
constexpr |
Overload the /= operator with a scalar.
lambda | the scalar to divide by |
Definition at line 271 of file Distance.hpp.
|
constexpr |
Overload the < operator.
rhs | the other Distance to check strict inferiority with |
Definition at line 298 of file Distance.hpp.
|
constexpr |
Overload the < operator.
rhs | the other Distance to check inferiority with |
Definition at line 302 of file Distance.hpp.
|
constexpr |
Overload the == operator.
rhs | the other Distance to check equality with |
Definition at line 282 of file Distance.hpp.
|
constexpr |
Overload the > operator.
rhs | the other Distance to check strict superiority with |
Definition at line 290 of file Distance.hpp.
|
constexpr |
Overload the > operator.
rhs | the other Distance to check superiority with |
Definition at line 294 of file Distance.hpp.
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
Overload the / operator with a scalar on the left side.
lambda | the scalar to multiply with |
Definition at line 310 of file Distance.hpp.
Overload the / operator between two distances.
lhs | the first distance |
rhs | the second distance |
Definition at line 306 of file Distance.hpp.