ACF $AcfVersion:0$
IModelEditor.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
6#include <istd/IPolymorphic.h>
7#include <istd/IChangeable.h>
8#include <imod/imod.h>
9
10
11namespace imod
12{
13
20class IModelEditor: virtual public istd::IPolymorphic
21{
22public:
27 {
31 CF_INIT_EDITOR = 0x3720694
32 };
33
39 virtual void UpdateEditor(const istd::IChangeable::ChangeSet& changeSet) = 0;
40
45 virtual void UpdateModelFromEditor() const = 0;
46
50 virtual bool IsReadOnly() const = 0;
51
56 virtual void SetReadOnly(bool state) = 0;
57};
58
59
60} // namespace imod
61
62
63
Common interface for an model editor.
ChangeFlags
Data model change notification flags.
@ CF_INIT_EDITOR
Called at begin of editor initialization.
virtual void UpdateEditor(const istd::IChangeable::ChangeSet &changeSet)=0
Updates editor with model data.
virtual bool IsReadOnly() const =0
Returns true if the model data can be changed.
virtual void UpdateModelFromEditor() const =0
Updates model from editor.
virtual void SetReadOnly(bool state)=0
Set flag that the model data can be changed.
Set of change flags (its IDs).
Definition IChangeable.h:36
Base interface for all used interfaces and implementations.
This namespace containes basic implementation of Model/Observer design pattern This package is system...
Definition CModelBase.h:16