Class Scine::Utils::StrongType

template<typename T, typename Parameter>
class StrongType

From: https://www.fluentcpp.com/2016/12/08/strong-types-for-strong-interfaces/.

Template Parameters
  • T: The underlying type.

  • Parameter: A “phantom type” serves the purpose of specializing the type.

Public Functions

constexpr StrongType(T const &value)

Copy Constructor.

constexpr StrongType(T &&value)

Move Constructor.

constexpr const T &get() const

Getter for the underlying base class.

Return

The value in its base from.