[7297] Fixed profession spells sorting in trainer spell list at client.
[getmangos.git] / dep / ACE_wrappers / ace / Hashable.h
blob83f26ffee193364924220fdc7a57eb17e12bd3fd
1 // -*- C++ -*-
3 //=============================================================================
4 /**
5 * @file Hashable.h
7 * $Id: Hashable.h 80826 2008-03-04 14:51:23Z wotte $
9 * @author Doug Schmidt
11 //=============================================================================
13 #ifndef ACE_HASHABLE_H
14 #define ACE_HASHABLE_H
16 #include /**/ "ace/pre.h"
18 #include /**/ "ace/ACE_export.h"
20 #if !defined (ACE_LACKS_PRAGMA_ONCE)
21 # pragma once
22 #endif /* ACE_LACKS_PRAGMA_ONCE */
24 ACE_BEGIN_VERSIONED_NAMESPACE_DECL
26 /**
27 * @class ACE_Hashable
29 * @brief ACE_Hashable
31 class ACE_Export ACE_Hashable
33 public:
35 /// Destructor.
36 virtual ~ACE_Hashable (void);
38 /// Computes and returns hash value. This "caches" the hash value to
39 /// improve performance.
40 virtual unsigned long hash (void) const;
42 protected:
43 /// Protected constructor.
44 ACE_Hashable (void);
46 /// This is the method that actually performs the non-cached hash
47 /// computation.
48 virtual unsigned long hash_i (void) const = 0;
50 protected:
52 /// Pre-computed hash-value.
53 mutable unsigned long hash_value_;
57 ACE_END_VERSIONED_NAMESPACE_DECL
59 #if defined (__ACE_INLINE__)
60 #include "ace/Hashable.inl"
61 #endif /* __ACE_INLINE __ */
63 #include /**/ "ace/post.h"
65 #endif /*ACE_HASHABLE_H*/