diff options
author | Rafael H. Schloming <rhs@apache.org> | 2007-07-31 22:34:12 +0000 |
---|---|---|
committer | Rafael H. Schloming <rhs@apache.org> | 2007-07-31 22:34:12 +0000 |
commit | 902481c5caf3a72538586a68cb779ddb9aa60c58 (patch) | |
tree | 6efbbe527de4a95a34a0033d9e87b3d848a90bcd /java/broker/src/main/java/org/apache/qpid/server/exchange/DefaultExchangeRegistry.java | |
parent | c11f9a79eec63da7aa6e6dac248a689a9d461beb (diff) | |
download | qpid-python-902481c5caf3a72538586a68cb779ddb9aa60c58.tar.gz |
Rolled back revision 561365 and commented out some broken code in ClientSession.java. The trunk should now build.
git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk/qpid@561578 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'java/broker/src/main/java/org/apache/qpid/server/exchange/DefaultExchangeRegistry.java')
-rw-r--r-- | java/broker/src/main/java/org/apache/qpid/server/exchange/DefaultExchangeRegistry.java | 19 |
1 files changed, 6 insertions, 13 deletions
diff --git a/java/broker/src/main/java/org/apache/qpid/server/exchange/DefaultExchangeRegistry.java b/java/broker/src/main/java/org/apache/qpid/server/exchange/DefaultExchangeRegistry.java index 377a73dd31..f3bdecc32e 100644 --- a/java/broker/src/main/java/org/apache/qpid/server/exchange/DefaultExchangeRegistry.java +++ b/java/broker/src/main/java/org/apache/qpid/server/exchange/DefaultExchangeRegistry.java @@ -20,20 +20,18 @@ */ package org.apache.qpid.server.exchange; +import java.util.concurrent.ConcurrentHashMap; +import java.util.concurrent.ConcurrentMap; + import org.apache.log4j.Logger; import org.apache.qpid.AMQException; import org.apache.qpid.framing.AMQShortString; import org.apache.qpid.server.protocol.ExchangeInitialiser; import org.apache.qpid.server.queue.AMQMessage; -import org.apache.qpid.server.store.MessageStore; import org.apache.qpid.server.virtualhost.VirtualHost; import org.apache.qpid.server.messageStore.MessageStore; import org.apache.qpid.server.exception.InternalErrorException; -import java.util.Collection; -import java.util.concurrent.ConcurrentHashMap; -import java.util.concurrent.ConcurrentMap; - public class DefaultExchangeRegistry implements ExchangeRegistry { private static final Logger _log = Logger.getLogger(DefaultExchangeRegistry.class); @@ -66,7 +64,7 @@ public class DefaultExchangeRegistry implements ExchangeRegistry public void registerExchange(Exchange exchange) throws AMQException { _exchangeMap.put(exchange.getName(), exchange); - if (exchange.isDurable()) + if(exchange.isDurable()) { try { @@ -88,18 +86,13 @@ public class DefaultExchangeRegistry implements ExchangeRegistry return _defaultExchange; } - public Collection<AMQShortString> getExchangeNames() - { - return _exchangeMap.keySet(); - } - public void unregisterExchange(AMQShortString name, boolean inUse) throws AMQException { // TODO: check inUse argument Exchange e = _exchangeMap.remove(name); if (e != null) { - if (e.isDurable()) + if(e.isDurable()) { try { @@ -119,7 +112,7 @@ public class DefaultExchangeRegistry implements ExchangeRegistry public Exchange getExchange(AMQShortString name) { - if ((name == null) || name.length() == 0) + if((name == null) || name.length() == 0) { return getDefaultExchange(); } |