Multi diag tools
Public Member Functions | Static Public Member Functions | List of all members
Mdt::Numeric::Resistance Class Reference

Value type that represents a resistance. More...

#include <Resistance.h>

+ Inheritance diagram for Mdt::Numeric::Resistance:
+ Collaboration diagram for Mdt::Numeric::Resistance:

Public Member Functions

constexpr Resistance () noexcept
 Construct a null resistance.
 
constexpr Resistance (Double r) noexcept
 Construct a resistance.
 
constexpr Resistance (double r) noexcept
 Construct a resistance.
 
- Public Member Functions inherited from Mdt::Numeric::PhysicsType< Resistance >
constexpr PhysicsType () noexcept=default
 Construct a null value.
 
constexpr PhysicsType (Double value) noexcept
 Construct a value.
 
constexpr Double value () const noexcept
 Get value.
 
constexpr bool isNull () const noexcept
 Check if value is null.
 
constexpr Resistance operator- () const
 Negation operator.
 
constexpr void clear () noexcept
 Clear value.
 

Static Public Member Functions

static Resistance fromQVariant (const QVariant &r)
 Get resistance from a QVariant. More...
 

Detailed Description

Value type that represents a resistance.

Definition at line 31 of file Resistance.h.

Member Function Documentation

static Resistance Mdt::Numeric::Resistance::fromQVariant ( const QVariant &  r)
inlinestatic

Get resistance from a QVariant.

If r is null, a null resistance is returned

Precondition
If r has a value (is not null), it must be convertible to double

Definition at line 56 of file Resistance.h.


The documentation for this class was generated from the following file: