GDCM: gdcmSubject.h Source File

GDCM 3.2.10

gdcmSubject.h
Go to the documentation of this file.
1/*=========================================================================
2
3 Program: GDCM (Grassroots DICOM). A DICOM library
4
5 Copyright (c) 2006-2011 Mathieu Malaterre
6 All rights reserved.
7 See Copyright.txt or http://gdcm.sourceforge.net/Copyright.html for details.
8
9 This software is distributed WITHOUT ANY WARRANTY; without even
10 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
11 PURPOSE. See the above copyright notice for more information.
12
13=========================================================================*/
14#ifndef GDCMSUBJECT_H
15#define GDCMSUBJECT_H
16
17#include "gdcmObject.h"
18
19namespace gdcm
20{
21class Event;
22class Command;
23class SubjectInternals;
28 class GDCM_EXPORT Subject : public Object
29{
30public:
31 Subject();
32 ~Subject() override;
33
42 unsigned long AddObserver(const Event & event, Command *);
43 unsigned long AddObserver(const Event & event, Command *) const;
44
50 Command* GetCommand(unsigned long tag);
51
53 void InvokeEvent( const Event & );
54
57 void InvokeEvent( const Event & ) const;
58
60 void RemoveObserver(unsigned long tag);
61
63 void RemoveAllObservers();
64
66 bool HasObserver( const Event & event ) const;
67
68protected:
69
70private:
71 SubjectInternals *Internals;
72private:
73};
74
75} // end namespace gdcm
76
77#endif //GDCMSUBJECT_H
gdcm::Command
Command superclass for callback/observer methods.
Definition gdcmCommand.h:28
gdcm::Event
superclass for callback/observer methods
Definition gdcmEvent.h:27
gdcm::Object::Object
Object()
Definition gdcmObject.h:42
gdcm::Subject::RemoveObserver
void RemoveObserver(unsigned long tag)
gdcm::Subject::InvokeEvent
void InvokeEvent(const Event &)
gdcm::Subject::GetCommand
Command * GetCommand(unsigned long tag)
gdcm::Subject::InvokeEvent
void InvokeEvent(const Event &) const
gdcm::Subject::RemoveAllObservers
void RemoveAllObservers()
gdcm::Subject::AddObserver
unsigned long AddObserver(const Event &event, Command *) const
gdcm::Subject::AddObserver
unsigned long AddObserver(const Event &event, Command *)
gdcm::Subject::~Subject
~Subject() override
gdcm::Subject::HasObserver
bool HasObserver(const Event &event) const
gdcm::Subject::Subject
Subject()
gdcmObject.h
GDCM_EXPORT
#define GDCM_EXPORT
Definition gdcmWin32.h:34
gdcm
Definition gdcmASN1.h:21