activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tab...@apache.org
Subject svn commit: r1460469 - /activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/state/ConnectionStateTracker.cpp
Date Sun, 24 Mar 2013 21:34:22 GMT
Author: tabish
Date: Sun Mar 24 21:34:22 2013
New Revision: 1460469

URL: http://svn.apache.org/r1460469
Log:
Simplified HashMap declaration now that Id commands have getHashCode.

Modified:
    activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/state/ConnectionStateTracker.cpp

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/state/ConnectionStateTracker.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/state/ConnectionStateTracker.cpp?rev=1460469&r1=1460468&r2=1460469&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/state/ConnectionStateTracker.cpp
(original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/state/ConnectionStateTracker.cpp
Sun Mar 24 21:34:22 2013
@@ -42,24 +42,11 @@ using namespace decaf::io;
 using namespace decaf::lang::exceptions;
 
 ////////////////////////////////////////////////////////////////////////////////
-namespace decaf {
-namespace util {
-
-    template<>
-    struct HashCode<MessageId> : public HashCodeUnaryBase<const MessageId&>
{
-        int operator()(const MessageId& arg) const {
-            return decaf::util::HashCode<std::string>()(arg.toString());
-        }
-    };
-
-}}
-
-////////////////////////////////////////////////////////////////////////////////
 namespace activemq {
 namespace state {
 
 
-    class MessageCache : public LinkedHashMap<Pointer<MessageId>, Pointer<Command>,
HashCode< Pointer<MessageId> > > {
+    class MessageCache : public LinkedHashMap<Pointer<MessageId>, Pointer<Command>
> {
     protected:
 
         ConnectionStateTracker* parent;
@@ -71,7 +58,7 @@ namespace state {
     public:
 
         MessageCache(ConnectionStateTracker* parent) :
-            LinkedHashMap<Pointer<MessageId>, Pointer<Command> >(), parent(parent),
currentCacheSize(0) {
+            LinkedHashMap(), parent(parent), currentCacheSize(0) {
         }
 
         virtual ~MessageCache() {}



Mime
View raw message