Functor_T.inl

Go to the documentation of this file.
00001 // -*- C++ -*-
00002 //
00003 // Functor_T.inl,v 4.2 2005/10/28 16:14:52 ossama Exp
00004 
00005 ACE_BEGIN_VERSIONED_NAMESPACE_DECL
00006 
00007 template <class TYPE> ACE_INLINE unsigned long
00008 ACE_Hash<TYPE>::operator () (const TYPE &t) const
00009 {
00010   return t.hash ();
00011 }
00012 
00013 template <class TYPE> ACE_INLINE unsigned long
00014 ACE_Pointer_Hash<TYPE>::operator () (TYPE t) const
00015 {
00016 #if defined (ACE_WIN64)
00017   // The cast below is legit... we only want a hash, and need not convert
00018   // the hash back to a pointer.
00019 #  pragma warning(push)
00020 #  pragma warning(disable : 4311)   /* Truncate pointer to unsigned long */
00021 #endif /* ACE_WIN64 */
00022   return reinterpret_cast<unsigned long> (t);
00023 #if defined (ACE_WIN64)
00024 #  pragma warning(pop)
00025 #endif /* ACE_WIN64 */
00026 }
00027 
00028 template <class TYPE> ACE_INLINE bool
00029 ACE_Equal_To<TYPE>::operator () (const TYPE &lhs,
00030                                  const TYPE &rhs) const
00031 {
00032   return lhs == rhs;
00033 }
00034 
00035 template <class TYPE> ACE_INLINE bool
00036 ACE_Less_Than<TYPE>::operator () (const TYPE &lhs,
00037                                   const TYPE &rhs) const
00038 {
00039   return lhs < rhs;
00040 }
00041 
00042 ACE_END_VERSIONED_NAMESPACE_DECL

Generated on Thu Nov 9 09:41:51 2006 for ACE by doxygen 1.3.6