diff options
Diffstat (limited to 'TAO/orbsvcs/orbsvcs/LoadBalancing/LB_ObjectGroup_Hash.h')
-rw-r--r-- | TAO/orbsvcs/orbsvcs/LoadBalancing/LB_ObjectGroup_Hash.h | 71 |
1 files changed, 71 insertions, 0 deletions
diff --git a/TAO/orbsvcs/orbsvcs/LoadBalancing/LB_ObjectGroup_Hash.h b/TAO/orbsvcs/orbsvcs/LoadBalancing/LB_ObjectGroup_Hash.h new file mode 100644 index 00000000000..488fa7bbc93 --- /dev/null +++ b/TAO/orbsvcs/orbsvcs/LoadBalancing/LB_ObjectGroup_Hash.h @@ -0,0 +1,71 @@ +// -*- C++ -*- +// +// $Id$ + +// ============================================================================ +// +// = LIBRARY +// TAO_LoadBalancing +// +// = FILENAME +// LB_Hash.h +// +// = AUTHOR +// Ossama Othman <ossama@uci.edu> +// +// ============================================================================ + +#ifndef TAO_LB_HASH_H +#define TAO_LB_HASH_H + +#include "ace/pre.h" + +#include "ace/config-all.h" + +#if !defined (ACE_LACKS_PRAGMA_ONCE) +# pragma once +#endif /* ACE_LACKS_PRAGMA_ONCE */ + +#include "LoadbalancingC.h" + +class TAO_LB_ObjectGroup_Hash +{ + // = TITLE + // Hash function object for generating a hash for an ObjectGroup + // reference. + // + // = DESCRIPTION + // This class basically wraps the CORBA::Object::_hash() method + // so that it can be utilized by a Hash Map. + +public: + + CORBA::ULong operator() (const TAO_LoadBalancing::ObjectGroup_ptr &) const; + // Invokes the _hash() method on the ObjectGroup reference. +}; + + +class TAO_LB_FactoryCreationId_Hash +{ + // = TITLE + // Hash function object for generating a hash for a + // FactoryCreationId. + // + // = DESCRIPTION + // Create a hash based on the contents of the FactoryCreationId. + +public: + + CORBA::ULong operator() (const TAO_LoadBalancing::FactoryCreationId &) const; + // Generates a hash value based on the contents of the + // FactoryCreationId. +}; + + +#if defined (__ACE_INLINE__) +#include "LB_Hash.inl" +#endif /* __ACE_INLINE__ */ + +#include "ace/post.h" + +#endif /* TAO_LB_HASH_H */ |