ServiceLifeTime¶
-
class ServiceLifeTime¶
Public Types
Public Functions
-
inline explicit constexpr ServiceLifeTime(const Type type)¶
Construct a new Service Life Time object with a specified type.
-
constexpr ServiceLifeTime(ServiceLifeTime&&) = default¶
-
constexpr ServiceLifeTime(const ServiceLifeTime&) = default¶
-
constexpr ServiceLifeTime &operator=(ServiceLifeTime&&) = default¶
-
constexpr ServiceLifeTime &operator=(const ServiceLifeTime&) = default¶
-
inline constexpr bool isSingleton() const¶
checks if lifetime is singleton
-
inline constexpr bool isScoped() const¶
checks if lifetime is scoped
-
inline constexpr bool isTransient() const¶
checks if lifetime is transient
-
inline constexpr bool operator!=(const ServiceLifeTime &lifeTime) const¶
-
inline constexpr bool operator==(const ServiceLifeTime &lifeTime) const¶
-
inline std::string_view toString() const¶
Public Static Functions
-
static inline constexpr ServiceLifeTime singleton()¶
creates singleton service lifetime
-
static inline constexpr ServiceLifeTime scoped()¶
creates scoped service lifetime
-
static inline constexpr ServiceLifeTime transient()¶
creates transient service lifetime
-
inline explicit constexpr ServiceLifeTime(const Type type)¶