Medical Imaging Interaction Toolkit  2021.02.99-e55a5d2f
Medical Imaging Interaction Toolkit
berryIContributionManager.h
Go to the documentation of this file.
1 /*============================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
4 
5 Copyright (c) German Cancer Research Center (DKFZ)
6 All rights reserved.
7 
8 Use of this source code is governed by a 3-clause BSD license that can be
9 found in the LICENSE file.
10 
11 ============================================================================*/
12 
13 
14 #ifndef BERRYICONTRIBUTIONMANAGER_H
15 #define BERRYICONTRIBUTIONMANAGER_H
16 
17 #include <berryMacros.h>
18 #include <berryObject.h>
19 
20 class QAction;
21 
22 namespace berry {
23 
24 struct IContributionItem;
25 struct IContributionManagerOverrides;
26 
45 struct IContributionManager : public virtual Object
46 {
47 
49 
57  virtual void Add(QAction* action, const QString& id) = 0;
58 
64  virtual void Add(const SmartPointer<IContributionItem>& item) = 0;
65 
78  virtual void AppendToGroup(const QString& groupName, QAction* action, const QString& id) = 0;
79 
89  virtual void AppendToGroup(const QString& groupName, const SmartPointer<IContributionItem>& item) = 0;
90 
98  virtual SmartPointer<IContributionItem> Find(const QString& id) const = 0;
99 
105  virtual QList<SmartPointer<IContributionItem> > GetItems() const = 0;
106 
113 
122  virtual void InsertAfter(const QString& id, const SmartPointer<IContributionItem>& item) = 0;
123 
132  virtual void InsertBefore(const QString& id, const SmartPointer<IContributionItem>& item) = 0;
133 
141  virtual bool IsDirty() const = 0;
142 
149  virtual bool IsEmpty() const = 0;
150 
154  virtual void MarkDirty() = 0;
155 
165  virtual void PrependToGroup(const QString& groupName, const SmartPointer<IContributionItem>& item) = 0;
166 
175  virtual SmartPointer<IContributionItem> Remove(const QString& id) = 0;
176 
186 
190  virtual void RemoveAll() = 0;
191 
201  virtual void Update(bool force) = 0;
202 };
203 
204 }
205 
206 #endif // BERRYICONTRIBUTIONMANAGER_H
virtual void Update(bool force)=0
virtual SmartPointer< IContributionManagerOverrides > GetOverrides()=0
Light weight base class for most BlueBerry classes.
Definition: berryObject.h:72
virtual void MarkDirty()=0
virtual void InsertAfter(const QString &id, const SmartPointer< IContributionItem > &item)=0
Implements transparent reference counting.
virtual SmartPointer< IContributionItem > Remove(const QString &id)=0
virtual SmartPointer< IContributionItem > Find(const QString &id) const =0
berryObjectMacro(berry::IContributionManager)
virtual void InsertBefore(const QString &id, const SmartPointer< IContributionItem > &item)=0
virtual bool IsEmpty() const =0
virtual void AppendToGroup(const QString &groupName, QAction *action, const QString &id)=0
virtual void Add(QAction *action, const QString &id)=0
virtual void RemoveAll()=0
virtual QList< SmartPointer< IContributionItem > > GetItems() const =0
virtual bool IsDirty() const =0
virtual void PrependToGroup(const QString &groupName, const SmartPointer< IContributionItem > &item)=0