00001 //Base_Transport_Property.cpp,v 1.5 2005/11/02 07:13:02 ossama Exp 00002 00003 #include "tao/Base_Transport_Property.h" 00004 #include "ace/OS_Memory.h" 00005 00006 #if !defined (__ACE_INLINE__) 00007 # include "tao/Base_Transport_Property.inl" 00008 #endif /* __ACE_INLINE__ */ 00009 00010 ACE_RCSID (tao, 00011 Base_Transport_Property, 00012 "Base_Transport_Property.cpp,v 1.5 2005/11/02 07:13:02 ossama Exp") 00013 00014 TAO_BEGIN_VERSIONED_NAMESPACE_DECL 00015 00016 TAO_Base_Transport_Property::~TAO_Base_Transport_Property (void) 00017 { 00018 } 00019 00020 TAO_Transport_Descriptor_Interface * 00021 TAO_Base_Transport_Property::duplicate (void) 00022 { 00023 // Get a copy of the underlying endpoint 00024 TAO_Endpoint *endpt = this->endpoint_->duplicate (); 00025 if (endpt == 0) 00026 return 0; 00027 00028 // Construct a copy of our class 00029 TAO_Base_Transport_Property *prop = 0; 00030 ACE_NEW_RETURN (prop, 00031 TAO_Base_Transport_Property (endpt, 00032 1), 00033 0); 00034 return prop; 00035 } 00036 00037 00038 CORBA::Boolean 00039 TAO_Base_Transport_Property::is_equivalent ( 00040 const TAO_Transport_Descriptor_Interface *rhs) 00041 { 00042 const TAO_Base_Transport_Property *other_desc = 00043 dynamic_cast<const TAO_Base_Transport_Property *> (rhs); 00044 00045 if (other_desc == 0) 00046 return 0; 00047 00048 return this->endpoint_->is_equivalent (other_desc->endpoint_); 00049 } 00050 00051 00052 u_long 00053 TAO_Base_Transport_Property::hash (void) const 00054 { 00055 return this->endpoint_->hash (); 00056 } 00057 00058 TAO_END_VERSIONED_NAMESPACE_DECL