Public Types | Public Member Functions | Protected Attributes
MAKLogger::DtObserveEvent< SubjectType > Class Template Reference

DtObserveEvent represents an event which observers can be connected to and when the event is fired using the observeSubject call each observer has it's own function called. More...

+ Inheritance diagram for MAKLogger::DtObserveEvent< SubjectType >:
+ Collaboration diagram for MAKLogger::DtObserveEvent< SubjectType >:

List of all members.

Public Types

typedef DtObserver< SubjectType > SubjectObserver
 Type definition for list of Observers.
typedef std::list< DtObserver
< SubjectType > * > 
ObserverList

Public Member Functions

 DtObserveEvent ()
 CTOR for the object. No parameters are used.
virtual ~DtObserveEvent ()
 DTOR for the class.
virtual void connect (DtObserveConnectionSP con)
 Connects an event to an existing shared connection.
virtual void disconnect (DtObserveConnectionSP con)
 Disconnects an event from a shared connection.
virtual void disconnect (SubjectObserver *observer)
 Disconnects the event from a specific observer.
void observeSubject (const SubjectType &value)
 The event call which will cause all observers to observe the provided subject object.

Protected Attributes

ObserverList myObservers
 A list of observers to call when inspecting.

Detailed Description

template<typename SubjectType>
class MAKLogger::DtObserveEvent< SubjectType >

DtObserveEvent represents an event which observers can be connected to and when the event is fired using the observeSubject call each observer has it's own function called.


Member Function Documentation

template<typename SubjectType>
virtual void MAKLogger::DtObserveEvent< SubjectType >::connect ( DtObserveConnectionSP  con) [inline, virtual]

Connects an event to an existing shared connection.

This function is used by the Connection object to connect Events to Observers.

Exceptions:
DtInvalidInputThrown if the ConnectionSP is null.
Postcondition:
Calls to inspect will call the observer in the input connection.
Warning:
This function is public but is not callable by user code.

Reimplemented from MAKLogger::DtObserveConnectionComponent.

Referenced by MAKLogger::DtObserveEvent< DtMessageState >::connect().

template<typename SubjectType>
virtual void MAKLogger::DtObserveEvent< SubjectType >::disconnect ( DtObserveConnectionSP  con) [inline, virtual]

Disconnects an event from a shared connection.

This function is only called by the Connection object to disconnect Events and Observers

Returns:
Return values:
<value><interpretations of="" value>="">
<value><interpretations of="" value>="">
Exceptions:
DtInvalidInputThrown if the ConnectionSP is null.
Precondition:
<what must="" be="" true="" before="" this="" function="" is="" called>="">
Postcondition:
<what will="" be="" true="" as="" a="" result="" of="" this="" function>="">
Warning:

Reimplemented from MAKLogger::DtObserveConnectionComponent.

Referenced by MAKLogger::DtObserveEvent< DtMessageState >::disconnect().

template<typename SubjectType>
void MAKLogger::DtObserveEvent< SubjectType >::observeSubject ( const SubjectType &  value) [inline]

The event call which will cause all observers to observe the provided subject object.


The documentation for this class was generated from the following file:

Document ID: Generated on Tue Oct 11 19:41:03 EDT 2011 from SVN revision 107422
Copyright © 2005-2011 VT MÄK Inc. All Rights Reserved (www.mak.com)