LocalObject.cpp

Go to the documentation of this file.
00001 #define TAOLIB_ERROR ACELIB_ERROR
00002 #define TAOLIB_DEBUG ACELIB_DEBUG
00003 
00004 #include "tao/LocalObject.h"
00005 
00006 #if !defined (__ACE_INLINE__)
00007 # include "tao/LocalObject.inl"
00008 #endif /* ! __ACE_INLINE__ */
00009 
00010 #include "tao/SystemException.h"
00011 #include "tao/debug.h"
00012 #include "tao/ORB_Constants.h"
00013 
00014 #include "ace/Log_Msg.h"
00015 #include "ace/Guard_T.h"
00016 
00017 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
00018 
00019 CORBA::LocalObject::~LocalObject (void)
00020 {
00021 }
00022 
00023 // Quickly hash an object reference's representation data.  Used to
00024 // create hash tables.
00025 
00026 CORBA::ULong
00027 CORBA::LocalObject::_hash (CORBA::ULong maximum)
00028 {
00029   // Note that we reinterpret_cast to an "ptrdiff_t" instead of
00030   // CORBA::ULong since we need to first cast to an integer large
00031   // enough to hold an address to avoid compile-time warnings on some
00032   // 64-bit platforms.
00033 
00034   CORBA::ULong const hash =
00035     static_cast<CORBA::ULong> (reinterpret_cast<ptrdiff_t> (this));
00036 
00037   return hash % maximum;
00038 }
00039 
00040 // Compare two object references to see if they point to the same
00041 // object.  Used in linear searches, as in hash buckets.
00042 //
00043 // XXX would be useful to also have a trivalued comparison predicate,
00044 // such as strcmp(), to allow more comparison algorithms.
00045 
00046 CORBA::Boolean
00047 CORBA::LocalObject::_is_equivalent (CORBA::Object_ptr other_obj)
00048 {
00049   return other_obj == this;
00050 }
00051 
00052 // TAO's extensions
00053 
00054 
00055 TAO::ObjectKey *
00056 CORBA::LocalObject::_key (void)
00057 {
00058   throw ::CORBA::NO_IMPLEMENT();
00059 }
00060 
00061 #if (TAO_HAS_MINIMUM_CORBA == 0)
00062 
00063 // NON_EXISTENT ... send a simple call to the object, which will
00064 // either elicit a FALSE response or a OBJECT_NOT_EXIST exception.  In
00065 // the latter case, return FALSE.
00066 
00067 CORBA::Boolean
00068 CORBA::LocalObject::_non_existent (void)
00069 {
00070   return false;
00071 }
00072 
00073 char *
00074 CORBA::LocalObject::_repository_id (void)
00075 {
00076   throw ::CORBA::NO_IMPLEMENT (CORBA::OMGVMCID | 8, CORBA::COMPLETED_NO);
00077 }
00078 
00079 #if ! defined (CORBA_E_COMPACT) && ! defined (CORBA_E_MICRO)
00080 void
00081 CORBA::LocalObject::_create_request (CORBA::Context_ptr,
00082                                      const char *,
00083                                      CORBA::NVList_ptr,
00084                                      CORBA::NamedValue_ptr,
00085                                      CORBA::Request_ptr &,
00086                                      CORBA::Flags)
00087 {
00088   throw ::CORBA::NO_IMPLEMENT (CORBA::OMGVMCID | 4, CORBA::COMPLETED_NO);
00089 }
00090 
00091 void
00092 CORBA::LocalObject::_create_request (CORBA::Context_ptr,
00093                                      const char *,
00094                                      CORBA::NVList_ptr,
00095                                      CORBA::NamedValue_ptr,
00096                                      CORBA::ExceptionList_ptr,
00097                                      CORBA::ContextList_ptr,
00098                                      CORBA::Request_ptr &,
00099                                      CORBA::Flags)
00100 {
00101   throw ::CORBA::NO_IMPLEMENT (CORBA::OMGVMCID | 4, CORBA::COMPLETED_NO);
00102 }
00103 
00104 CORBA::Request_ptr
00105 CORBA::LocalObject::_request (const char *)
00106 {
00107   throw ::CORBA::NO_IMPLEMENT (CORBA::OMGVMCID | 4, CORBA::COMPLETED_NO);
00108 }
00109 
00110 CORBA::Object_ptr
00111 CORBA::LocalObject::_get_component (void)
00112 {
00113   throw ::CORBA::NO_IMPLEMENT (CORBA::OMGVMCID | 8, CORBA::COMPLETED_NO);
00114 }
00115 
00116 CORBA::InterfaceDef_ptr
00117 CORBA::LocalObject::_get_interface (void)
00118 {
00119   throw ::CORBA::NO_IMPLEMENT (CORBA::OMGVMCID | 8, CORBA::COMPLETED_NO);
00120 }
00121 #endif
00122 
00123 #endif /* TAO_HAS_MINIMUM_CORBA */
00124 
00125 #if (TAO_HAS_CORBA_MESSAGING == 1)
00126 
00127 CORBA::Policy_ptr
00128 CORBA::LocalObject::_get_policy (CORBA::PolicyType)
00129 {
00130   throw ::CORBA::NO_IMPLEMENT (CORBA::OMGVMCID | 8, CORBA::COMPLETED_NO);
00131 }
00132 
00133 CORBA::Policy_ptr
00134 CORBA::LocalObject::_get_cached_policy (TAO_Cached_Policy_Type)
00135 {
00136   throw ::CORBA::NO_IMPLEMENT ();
00137 }
00138 
00139 CORBA::Object_ptr
00140 CORBA::LocalObject::_set_policy_overrides (const CORBA::PolicyList &,
00141                                            CORBA::SetOverrideType)
00142 {
00143   throw ::CORBA::NO_IMPLEMENT (CORBA::OMGVMCID | 8, CORBA::COMPLETED_NO);
00144 }
00145 
00146 CORBA::PolicyList *
00147 CORBA::LocalObject::_get_policy_overrides (const CORBA::PolicyTypeSeq &)
00148 {
00149   throw ::CORBA::NO_IMPLEMENT (CORBA::OMGVMCID | 8, CORBA::COMPLETED_NO);
00150 }
00151 
00152 CORBA::Boolean
00153 CORBA::LocalObject::_validate_connection (CORBA::PolicyList_out)
00154 {
00155   throw ::CORBA::NO_IMPLEMENT (CORBA::OMGVMCID | 8, CORBA::COMPLETED_NO);
00156 }
00157 
00158 #endif /* TAO_HAS_CORBA_MESSAGING == 1 */
00159 
00160 CORBA::ORB_ptr
00161 CORBA::LocalObject::_get_orb (void)
00162 {
00163   throw ::CORBA::NO_IMPLEMENT (CORBA::OMGVMCID | 8, CORBA::COMPLETED_NO);
00164 }
00165 
00166 TAO_END_VERSIONED_NAMESPACE_DECL

Generated on Fri Feb 12 20:05:23 2016 for OpenDDS by  doxygen 1.4.7