ACF $AcfVersion:0$
TChangeDelegator.h
Go to the documentation of this file.
1// SPDX-License-Identifier: LGPL-2.1-or-later OR GPL-2.0-or-later OR GPL-3.0-or-later OR LicenseRef-ACF-Commercial
2#pragma once
3
4
5// ACF includes
7
8
9namespace istd
10{
11
12
19template <class Base>
21 public Base,
22 public CChangeDelegator
23{
24public:
25 typedef Base BaseClass;
27
30
31 // reimplemented (istd::IChangeable)
32 virtual void OnBeginChanges() override;
33 virtual void OnEndChanges(const istd::IChangeable::ChangeSet& changeSet) override;
34};
35
36
37// public methods
38
39template <class Base>
43
44
45template <class Base>
47{
48 BaseClass2::SetSlavePtr(slavePtr);
49}
50
51
52// pseudo-reimplemented (istd::IChangeable)
53
54template <class Base>
56{
57 BaseClass2::OnBeginChanges();
58
59 BaseClass::OnBeginChanges();
60}
61
62
63template <class Base>
65{
66 BaseClass::OnEndChanges(changeSet);
67
68 BaseClass2::OnEndChanges(changeSet);
69}
70
71
72} // namespace istd
73
74
75
Delegates calls of IChangeable methods to the given slave.
Set of change flags (its IDs).
Definition IChangeable.h:36
Common interface for data model objects, which can be changed.
Definition IChangeable.h:28
Binder of some istd::IChangeable implementation and changing delegator.
TChangeDelegator(istd::IChangeable *slavePtr)
CChangeDelegator BaseClass2
virtual void OnEndChanges(const istd::IChangeable::ChangeSet &changeSet) override
Callback function for end change event.
virtual void OnBeginChanges() override
Callback function for begin change event.
Standard library.
Definition IComponent.h:17