VR-Link API Documentation for DIS
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
vlObserver.h
Go to the documentation of this file.
1 /*******************************************************************************
2 ** Copyright (c) 1992-2010 VT MAK
3 ** All rights reserved.
4 *******************************************************************************/
8 #pragma once
9 
10 #include "vlList.h"
11 #include "vlMachineTypes.h"
12 #include "vlDeclNotifier.h"
13 
14 #ifdef DtUSE_UTILITIES_NAMESPACE
15 namespace DtUSE_UTILITIES_NAMESPACE
16 {
17 #endif
18 
19 class DtObserver;
21 
23 
37 {
38 public:
39 
41  DtObserver();
42 
45  virtual ~DtObserver();
46 
50  DtObserver(const DtObserver& orig);
51 
57  DtObserver& operator=(const DtObserver& orig);
58 
60  virtual bool startObserving(DtObservee* toObserve);
61 
63  virtual bool stopObserving(DtObservee* observed);
64 
66  virtual bool isBeingObserved(DtObservee* object);
67 
71  virtual bool notifyFromYourObserved(
72  const DtObservee* observed,
74 
75 protected:
76 
84  virtual bool pendingDeleteOfYourObserved(const DtObservee* observed);
85 
93  virtual bool deleteOfYourObserved(const DtObservee* observed);
94 
99  virtual bool removeObservedReference(const DtObservee* observed);
100 
104 
109  bool internalStartObserving(DtObservee* toObserve);
110 
115  bool internalStopObserving(DtObservee* observed);
116 
117 protected:
118 
121 
123  DtObserverNotifier myNotifier;
124 };
125 
126 #ifdef DtUSE_UTILITIES_NAMESPACE
127 }
128 #endif
129 
130 
This file contains the declaration of DtList and DtListItem.
DtWhyNotifyObserver
The observed object calls DtAbsNotifyObserver::notifyFromObserved() with the following values to noti...
Definition: vlObservee.h:45
#define DtDECLARE_OBSERVER_NOTIFIER(ClassName)
Creates a notifier used for notifying a <ClassName> object which is observing a DtObservee.
Definition: vlDeclNotifier.h:26
Instances of DtObservee are used to manage interest in this object by other objects, i.e.
Definition: vlObservee.h:39
DtObserverNotifier myNotifier
Used to get notification from objects this object is observing.
Definition: vlObserver.h:123
Instances of DtObserver are used to manage interest in other objects by this object.
Definition: vlObserver.h:36
DtList is deprecated, please use std::list<T>.
Definition: vlList.h:71
Macros useful for creating Notifiers for a DtObservee.
Definition: entityTypes.h:34
DtAbsNotifyObserver is an abstract base class.
Definition: vlAbsNotifyObs.h:24
DtList myObjectsAmObserving
List of DtObservee's which this object is observing.
Definition: vlObserver.h:120
DtAbsNotifyObserver & operator=(const DtAbsNotifyObserver &orig)
assignment operator
This file contains typedefs for machine dependant types.
#define DT_DLL_VLUTIL
Definition: vlMachineTypes.h:109

Document ID: Generated on Tue Feb 2 21:02:17 EST 2021 from SVN revision 223668
Copyright © 2005-2021 MAK Technologies. All Rights Reserved (www.mak.com)