33#include <NDEVR/ResourceListener.h>
41 class Resource final :
public ResourceBase
53 void set(
const T& info,
bool check_equal =
true)
62 void set(T&& info,
bool check_equal =
true)
68 std::swap(m_value, info);
89 return value == m_value;
A base class for templated resources.
Definition ResourceListener.h:43
A core part of the engine, stores variables that can be listened to with ResourceListener which will ...
Definition Toggle.h:41
Resource(const Resource< T > &value)=delete
Resource(const T &value)
Definition Resource.h:44
T & getModifiable()
Definition Resource.h:81
const T & get() const
Definition Resource.h:71
virtual ~Resource()
Definition Resource.h:51
bool isEqualTo(const T &value) const
Definition Resource.h:87
void set(T &&info, bool check_equal=true)
Definition Resource.h:62
Resource< T > & operator=(const Resource< T > &)=delete
void getCopy(T ©) const
Definition Resource.h:76
void set(const T &info, bool check_equal=true)
Definition Resource.h:53