diff options
author | smcqueen <smcqueen@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2005-06-09 12:16:07 +0000 |
---|---|---|
committer | smcqueen <smcqueen@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2005-06-09 12:16:07 +0000 |
commit | 62aa316bc5564669a3a4a4526c5a7cb4e095eebd (patch) | |
tree | be350e5251fb9d61c7bfb4d6736ff0c3b53668c7 /TAO/tao/Profile.cpp | |
parent | 78c0b7f7a23a959e53b070b29c157192b8e70bbf (diff) | |
download | ATCD-62aa316bc5564669a3a4a4526c5a7cb4e095eebd.tar.gz |
ChangeLogTag: Thu Jun 9 12:54:41 2005 Simon McQueen <sm@prismtech.com>
Diffstat (limited to 'TAO/tao/Profile.cpp')
-rw-r--r-- | TAO/tao/Profile.cpp | 32 |
1 files changed, 21 insertions, 11 deletions
diff --git a/TAO/tao/Profile.cpp b/TAO/tao/Profile.cpp index b092c5c5c54..bd9aaa3a247 100644 --- a/TAO/tao/Profile.cpp +++ b/TAO/tao/Profile.cpp @@ -700,17 +700,27 @@ TAO_Profile::parse_string (const char *ior CORBA::Boolean TAO_Profile::is_equivalent (const TAO_Profile *other) { - return - other != 0 - && this->tag () == other->tag () - && this->version_ == other->version () - && this->endpoint_count () == other->endpoint_count () - && this->object_key () == other->object_key () - && this->do_is_equivalent (other) - && this->is_equivalent_hook (other); + CORBA::Boolean result = 0; + if (other) + { + TAO_Service_Callbacks::Profile_Equivalence callback + = this->is_equivalent_hook (other); + switch (callback) + { + case TAO_Service_Callbacks::DONT_KNOW: + return this->tag () == other->tag () + && this->version_ == other->version () + && this->endpoint_count () == other->endpoint_count () + && this->object_key () == other->object_key () + && this->do_is_equivalent (other); + case TAO_Service_Callbacks::EQUIVALENT: + result = 1; + } + } + return result; } -CORBA::Boolean +TAO_Service_Callbacks::Profile_Equivalence TAO_Profile::is_equivalent_hook (const TAO_Profile *other) { // Allow services to apply their own definition of "equivalence." @@ -832,13 +842,13 @@ TAO_Unknown_Profile::do_is_equivalent (const TAO_Profile* other_profile) return (CORBA::Boolean) (op == 0 ? 0 : this->body_ == op->body_); } -CORBA::Boolean +TAO_Service_Callbacks::Profile_Equivalence TAO_Unknown_Profile::is_equivalent_hook (const TAO_Profile * /* other */) { // Override the default implementation since we don't need the // additional checks it performs. - return 1; + return TAO_Service_Callbacks::DONT_KNOW; } CORBA::ULong |