]> git.stg.codes - stg.git/blob - include/stg/notifer.h
367c5ced998a111618d7d7aa9259905a8057be01
[stg.git] / include / stg / notifer.h
1 #pragma once
2
3 namespace STG
4 {
5
6 template <typename T>
7 struct PropertyNotifierBase
8 {
9     virtual ~PropertyNotifierBase() = default;
10
11     virtual void Notify(const T& oldValue, const T& newValue) = 0;
12 };
13
14 template <typename T>
15 struct NotifierBase
16 {
17     virtual ~NotifierBase() = default;
18
19     virtual void Notify(const T& value) = 0;
20 };
21
22 }