TAO_ECG_Mcast_Gateway::Attributes Struct Reference
Helper class to initialize a TAO_ECG_Mcast_Gateway.
More...
#include <ECG_Mcast_Gateway.h>
Collaboration diagram for TAO_ECG_Mcast_Gateway::Attributes:
[legend]List of all members.
Detailed Description
Helper class to initialize a TAO_ECG_Mcast_Gateway.
The TAO_ECG_Mcast_Gateway class has several properties that can be configured at initialization time, with default values. The canonical trick of using a constructor or init() method with multiple arguments does not work because to change the last argument the application developer needs to know all the other defaults.
Instead we define a helper class that initializes all the fields to reasonable defaults. The application only sets the fields that it is interested into, if new fields are added applications do not need to change.
With a little trickery we can even eliminate named temporaries:
TAO_ECG_Mcast_Gateway gw;
gw.init(TAO_ECG_Mcast_Gateway::Attributes().set_foo(x).set_bar(y));
but we are not implementing that one (detecting errors is too hard without exceptions and ACE+TAO are somewhat shy of exceptions at this point.)
Constructor & Destructor Documentation
ACE_INLINE TAO_ECG_Mcast_Gateway::Attributes::Attributes |
( |
void |
|
) |
|
|
Member Data Documentation
The documentation for this struct was generated from the following files:
Generated on Thu Feb 10 20:51:55 2005 for TAO_RTEvent by
1.3.9.1