#include <PropertySeq.h>
Inheritance diagram for TAO_Notify_PropertySeq:


Public Member Functions | |
| TAO_Notify_PropertySeq (void) | |
| Constuctor. | |
| ~TAO_Notify_PropertySeq () | |
| Destructor. | |
| int | init (const CosNotification::PropertySeq &prop_seq) |
| Return 0 on success, -1 on error. | |
| int | find (const char *name, CosNotification::PropertyValue &value) const |
| Find the for property . Returns 0 on success. | |
| int | populate (CosNotification::PropertySeq_var &prop_seq) const |
| Return -1 on error. | |
| size_t | size () const |
| return the number of properties available as a sequence | |
Protected Types | |
| typedef ACE_Hash_Map_Manager< ACE_CString, CosNotification::PropertyValue, ACE_SYNCH_NULL_MUTEX > | PROPERTY_MAP |
| Property Map. | |
Protected Member Functions | |
| void | add (const ACE_CString &name, const CORBA::Any &val) |
Protected Attributes | |
| PROPERTY_MAP | property_map_ |
|
|
Property Map.
Definition at line 64 of file PropertySeq.h. |
|
|
Constuctor.
Definition at line 13 of file PropertySeq.cpp.
00014 {
00015 }
|
|
|
Destructor.
Definition at line 17 of file PropertySeq.cpp.
00018 {
00019 }
|
|
||||||||||||
|
Add the value. Used by subclasses to initialize the property map from their member variables. Definition at line 58 of file PropertySeq.cpp. References ACE_ASSERT, property_map_, and ACE_Hash_Map_Manager_Ex< EXT_ID, INT_ID, ACE_Hash< EXT_ID >, ACE_Equal_To< EXT_ID >, ACE_LOCK >::rebind(). Referenced by TAO_Notify_QoSProperties::init(), and TAO_Notify_AdminProperties::init().
00059 {
00060 int ret = this->property_map_.rebind (name, val);
00061 ACE_ASSERT(ret >= 0);
00062 ACE_UNUSED_ARG (ret); // because the assert disappears in release builds
00063 }
|
|
||||||||||||
|
Find the for property . Returns 0 on success.
Definition at line 8 of file PropertySeq.inl. References ACE_CString, ACE_Hash_Map_Manager_Ex< EXT_ID, INT_ID, ACE_Hash< EXT_ID >, ACE_Equal_To< EXT_ID >, ACE_LOCK >::find(), property_map_, and CosNotification::PropertyValue. Referenced by TAO_Notify_Object::find_qos_property_value(), TAO_Notify_StructProperty_T< TYPE >::set(), TAO_Notify_Property_T< TYPE >::set(), and TAO_Notify_Property_Boolean::set().
00010 {
00011 ACE_CString str_name (name);
00012 return this->property_map_.find (str_name, value);
00013 }
|
|
|
Return 0 on success, -1 on error.
Reimplemented in TAO_Notify_AdminProperties. Definition at line 22 of file PropertySeq.cpp. References ACE_CString, property_map_, CosNotification::PropertySeq, and ACE_Hash_Map_Manager_Ex< EXT_ID, INT_ID, ACE_Hash< EXT_ID >, ACE_Equal_To< EXT_ID >, ACE_LOCK >::rebind(). Referenced by TAO_Notify_AdminProperties::init().
00023 {
00024 ACE_CString name;
00025
00026 for (CORBA::ULong i = 0; i < prop_seq.length (); ++i)
00027 {
00028 name = prop_seq[i].name.in ();
00029
00030 if (this->property_map_.rebind (name, prop_seq[i].value) == -1)
00031 return -1;
00032 }
00033 // Note call to rebind. This allows to call <init> to set updates.
00034
00035 return 0;
00036 }
|
|
|
Return -1 on error.
Definition at line 39 of file PropertySeq.cpp. References CORBA::string_dup(). Referenced by TAO_Notify_Object::get_qos().
00040 {
00041 PROPERTY_MAP::CONST_ITERATOR iterator (this->property_map_);
00042
00043 int index = prop_seq->length ();
00044 prop_seq->length (static_cast<CORBA::ULong> (index + this->property_map_.current_size ()));
00045
00046 for (PROPERTY_MAP::ENTRY *entry = 0;
00047 iterator.next (entry) != 0;
00048 iterator.advance (), ++index)
00049 {
00050 (*prop_seq)[index].name = CORBA::string_dup (entry->ext_id_.c_str ());
00051 (*prop_seq)[index].value = entry->int_id_;
00052 }
00053
00054 return 0;
00055 }
|
|
|
return the number of properties available as a sequence
Definition at line 17 of file PropertySeq.inl. References ACE_Hash_Map_Manager_Ex< EXT_ID, INT_ID, ACE_Hash< EXT_ID >, ACE_Equal_To< EXT_ID >, ACE_LOCK >::current_size(), and property_map_.
00018 {
00019 return this->property_map_.current_size();
00020 }
|
|
|
Definition at line 66 of file PropertySeq.h. Referenced by add(), TAO_Notify_QoSProperties::copy(), find(), init(), size(), and TAO_Notify_QoSProperties::transfer(). |
1.3.6