TAO_Notify_Property_Boolean Class Reference

Boolean Property. More...

#include <Property_Boolean.h>

List of all members.

Public Member Functions

 TAO_Notify_Property_Boolean (const char *name, CORBA::Boolean initial)
 Constuctor.

 TAO_Notify_Property_Boolean (const char *name)
 Constuctor.

TAO_Notify_Property_Booleanoperator= (const TAO_Notify_Property_Boolean &rhs)
 Assignment from TAO_Notify_Property_Boolean.

TAO_Notify_Property_Booleanoperator= (const CORBA::Boolean &rhs)
 Assignment from CORBA::Boolean.

bool operator== (const CORBA::Boolean &rhs) const
 Equality comparison operator.

bool operator!= (const CORBA::Boolean &rhs) const
 Inequality comparison operator.

int set (const TAO_Notify_PropertySeq &property_seq)
void get (CosNotification::PropertySeq &prop_seq)
const char * name (void) const
 Return the name.

CORBA::Boolean value (void) const
 Return the value.

CORBA::Boolean is_valid (void) const
 Is the current value valid.


Protected Attributes

const char * name_
 The Property name.

CORBA::Boolean value_
 The value.

CORBA::Boolean valid_
 Is the value valid.


Detailed Description

Boolean Property.

Definition at line 36 of file Property_Boolean.h.


Constructor & Destructor Documentation

TAO_Notify_Property_Boolean::TAO_Notify_Property_Boolean const char *  name,
CORBA::Boolean  initial
 

Constuctor.

Definition at line 20 of file Property_Boolean.cpp.

00021   :name_ (name), value_ (initial), valid_ (1)
00022 {
00023 }

TAO_BEGIN_VERSIONED_NAMESPACE_DECL TAO_Notify_Property_Boolean::TAO_Notify_Property_Boolean const char *  name  ) 
 

Constuctor.

Definition at line 15 of file Property_Boolean.cpp.

00016   : name_ (name), valid_(0)
00017 {
00018 }


Member Function Documentation

void TAO_Notify_Property_Boolean::get CosNotification::PropertySeq prop_seq  ) 
 

Make space

Definition at line 39 of file Property_Boolean.cpp.

References CosNotification::PropertySeq.

00040 {
00041   /// Make space
00042   prop_seq.length (prop_seq.length () + 1);
00043 
00044   prop_seq[prop_seq.length () - 1].value <<= CORBA::Any::from_boolean (this->value_);
00045 }

ACE_INLINE CORBA::Boolean TAO_Notify_Property_Boolean::is_valid void   )  const
 

Is the current value valid.

Definition at line 57 of file Property_Boolean.inl.

References valid_.

Referenced by TAO_Notify_QoSProperties::init(), TAO_Notify_AdminProperties::init(), and operator=().

00058 {
00059   return this->valid_;
00060 }

ACE_INLINE const char * TAO_Notify_Property_Boolean::name void   )  const
 

Return the name.

Definition at line 45 of file Property_Boolean.inl.

Referenced by TAO_Notify::NVPList::load().

00046 {
00047   return this->name_;
00048 }

ACE_INLINE bool TAO_Notify_Property_Boolean::operator!= const CORBA::Boolean rhs  )  const
 

Inequality comparison operator.

Definition at line 38 of file Property_Boolean.inl.

00039 {
00040   return (this->value_ != rhs);
00041 }

ACE_INLINE TAO_Notify_Property_Boolean & TAO_Notify_Property_Boolean::operator= const CORBA::Boolean rhs  ) 
 

Assignment from CORBA::Boolean.

Definition at line 24 of file Property_Boolean.inl.

00025 {
00026   this->value_ = value;
00027 
00028   return *this;
00029 }

TAO_BEGIN_VERSIONED_NAMESPACE_DECL ACE_INLINE TAO_Notify_Property_Boolean & TAO_Notify_Property_Boolean::operator= const TAO_Notify_Property_Boolean rhs  ) 
 

Assignment from TAO_Notify_Property_Boolean.

Definition at line 8 of file Property_Boolean.inl.

References is_valid(), name_, valid_, and value_.

00009 {
00010   if (this == &rhs)
00011     return *this;
00012 
00013   if (rhs.is_valid ())
00014     {
00015       this->name_ = rhs.name_;
00016       this->value_ = rhs.value_;
00017       this->valid_ = rhs.valid_;
00018     }
00019 
00020   return *this;
00021 }

ACE_INLINE bool TAO_Notify_Property_Boolean::operator== const CORBA::Boolean rhs  )  const
 

Equality comparison operator.

Definition at line 32 of file Property_Boolean.inl.

00033 {
00034   return (this->value_ == rhs);
00035 }

int TAO_Notify_Property_Boolean::set const TAO_Notify_PropertySeq property_seq  ) 
 

Definition at line 26 of file Property_Boolean.cpp.

References TAO_Notify_PropertySeq::find(), and CosNotification::PropertyValue.

Referenced by TAO_Notify_QoSProperties::init(), and TAO_Notify_AdminProperties::init().

00027 {
00028   CosNotification::PropertyValue value;
00029 
00030   if (property_seq.find (this->name_, value) == -1)
00031     return -1;
00032 
00033   value >>= CORBA::Any::to_boolean (this->value_);
00034 
00035   return 0;
00036 }

ACE_INLINE CORBA::Boolean TAO_Notify_Property_Boolean::value void   )  const
 

Return the value.

Definition at line 51 of file Property_Boolean.inl.

Referenced by TAO_Notify::NVP::NVP().

00052 {
00053   return this->value_;
00054 }


Member Data Documentation

const char* TAO_Notify_Property_Boolean::name_ [protected]
 

The Property name.

Definition at line 72 of file Property_Boolean.h.

Referenced by operator=().

CORBA::Boolean TAO_Notify_Property_Boolean::valid_ [protected]
 

Is the value valid.

Definition at line 78 of file Property_Boolean.h.

Referenced by is_valid(), and operator=().

CORBA::Boolean TAO_Notify_Property_Boolean::value_ [protected]
 

The value.

Definition at line 75 of file Property_Boolean.h.

Referenced by operator=().


The documentation for this class was generated from the following files:
Generated on Thu Nov 9 13:32:32 2006 for TAO_CosNotification by doxygen 1.3.6