diff options
Diffstat (limited to 'TAO/orbsvcs/orbsvcs/LoadBalancing/LB_ObjectGroup_Hash.inl')
-rw-r--r-- | TAO/orbsvcs/orbsvcs/LoadBalancing/LB_ObjectGroup_Hash.inl | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/TAO/orbsvcs/orbsvcs/LoadBalancing/LB_ObjectGroup_Hash.inl b/TAO/orbsvcs/orbsvcs/LoadBalancing/LB_ObjectGroup_Hash.inl new file mode 100644 index 00000000000..fe12be1ad3f --- /dev/null +++ b/TAO/orbsvcs/orbsvcs/LoadBalancing/LB_ObjectGroup_Hash.inl @@ -0,0 +1,25 @@ +// -*- C++ -*- +// +// $Id$ + +ACE_INLINE CORBA::ULong +TAO_LB_ObjectGroup_Hash::operator() ( + const TAO_LoadBalancing::ObjectGroup_ptr &object_group) const +{ + CORBA::ULong max = 4294967295UL; // Maximum 32-bit unsigned integer + return object_group->_hash (max); +} + +// ------------------------------------------------------------------- + +ACE_INLINE CORBA::ULong +TAO_LB_FactoryCreationId_Hash::operator() ( + const TAO_LoadBalancing::FactoryCreationId &factory_creation_id) const +{ + // A Load Balancer FactoryCreationId is simply a CORBA::ULong. + + CORBA::ULong id; + factory_creation_id >>= id; + + return id; +} |