activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From clebertsuco...@apache.org
Subject [47/53] [abbrv] [partial] activemq-artemis git commit: automatic checkstyle change
Date Mon, 10 Aug 2015 15:13:46 GMT
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/bac96047/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/BasicSecurityHandler.java
----------------------------------------------------------------------
diff --git a/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/BasicSecurityHandler.java b/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/BasicSecurityHandler.java
index ebd71e4..b8eb2a5 100644
--- a/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/BasicSecurityHandler.java
+++ b/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/BasicSecurityHandler.java
@@ -24,14 +24,10 @@ import org.apache.activemq.artemis.dto.SecurityDTO;
 import org.apache.activemq.artemis.spi.core.security.ActiveMQSecurityManager;
 import org.apache.activemq.artemis.spi.core.security.ActiveMQSecurityManagerImpl;
 
-public class BasicSecurityHandler implements SecurityHandler
-{
+public class BasicSecurityHandler implements SecurityHandler {
 
-
-   static String fixupFileURI(String value)
-   {
-      if (value != null && value.startsWith("file:"))
-      {
+   static String fixupFileURI(String value) {
+      if (value != null && value.startsWith("file:")) {
          value = value.substring("file:".length());
          value = new File(value).toURI().toString();
       }
@@ -39,15 +35,10 @@ public class BasicSecurityHandler implements SecurityHandler
    }
 
    @Override
-   public ActiveMQSecurityManager createSecurityManager(SecurityDTO security) throws Exception
-   {
+   public ActiveMQSecurityManager createSecurityManager(SecurityDTO security) throws Exception {
       BasicSecurityDTO fileSecurity = (BasicSecurityDTO) security;
       String home = System.getProperty("activemq.home");
-      FileSecurityConfiguration securityConfiguration = new FileSecurityConfiguration(fixupFileURI(fileSecurity.users),
-                                                                                      fixupFileURI(fileSecurity.roles),
-                                                                                      fileSecurity.defaultUser,
-                                                                                      fileSecurity.maskPassword,
-                                                                                      fileSecurity.passwordCodec);
+      FileSecurityConfiguration securityConfiguration = new FileSecurityConfiguration(fixupFileURI(fileSecurity.users), fixupFileURI(fileSecurity.roles), fileSecurity.defaultUser, fileSecurity.maskPassword, fileSecurity.passwordCodec);
       securityConfiguration.start();
       return new ActiveMQSecurityManagerImpl(securityConfiguration);
    }

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/bac96047/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/BrokerFactory.java
----------------------------------------------------------------------
diff --git a/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/BrokerFactory.java b/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/BrokerFactory.java
index edcfd7f..6ca026b 100644
--- a/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/BrokerFactory.java
+++ b/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/BrokerFactory.java
@@ -27,60 +27,47 @@ import org.apache.activemq.artemis.integration.Broker;
 import org.apache.activemq.artemis.spi.core.security.ActiveMQSecurityManager;
 import org.apache.activemq.artemis.utils.FactoryFinder;
 
-public class BrokerFactory
-{
+public class BrokerFactory {
 
-   public static BrokerDTO createBrokerConfiguration(URI configURI) throws Exception
-   {
-      if (configURI.getScheme() == null)
-      {
+   public static BrokerDTO createBrokerConfiguration(URI configURI) throws Exception {
+      if (configURI.getScheme() == null) {
          throw new ConfigurationException("Invalid configuration URI, no scheme specified: " + configURI);
       }
 
       BrokerFactoryHandler factory = null;
-      try
-      {
+      try {
          FactoryFinder finder = new FactoryFinder("META-INF/services/org/apache/activemq/artemis/broker/");
          factory = (BrokerFactoryHandler) finder.newInstance(configURI.getScheme());
       }
-      catch (IOException ioe)
-      {
+      catch (IOException ioe) {
          throw new ConfigurationException("Invalid configuration URI, can't find configuration scheme: " + configURI.getScheme());
       }
 
-
       return factory.createBroker(configURI);
    }
 
-   public static BrokerDTO createBrokerConfiguration(String configuration) throws Exception
-   {
+   public static BrokerDTO createBrokerConfiguration(String configuration) throws Exception {
       return createBrokerConfiguration(new URI(configuration));
    }
 
-   static String fixupFileURI(String value)
-   {
-      if (value != null && value.startsWith("file:"))
-      {
+   static String fixupFileURI(String value) {
+      if (value != null && value.startsWith("file:")) {
          value = value.substring("file:".length());
          value = new File(value).toURI().toString();
       }
       return value;
    }
 
-   public static Broker createServer(ServerDTO brokerDTO, ActiveMQSecurityManager security) throws Exception
-   {
-      if (brokerDTO.configuration != null)
-      {
+   public static Broker createServer(ServerDTO brokerDTO, ActiveMQSecurityManager security) throws Exception {
+      if (brokerDTO.configuration != null) {
          BrokerHandler handler;
          URI configURI = brokerDTO.getConfigurationURI();
 
-         try
-         {
+         try {
             FactoryFinder finder = new FactoryFinder("META-INF/services/org/apache/activemq/artemis/broker/server/");
             handler = (BrokerHandler) finder.newInstance(configURI.getScheme());
          }
-         catch (IOException ioe)
-         {
+         catch (IOException ioe) {
             throw new ConfigurationException("Invalid configuration URI, can't find configuration scheme: " + configURI.getScheme());
          }
 

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/bac96047/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/BrokerFactoryHandler.java
----------------------------------------------------------------------
diff --git a/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/BrokerFactoryHandler.java b/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/BrokerFactoryHandler.java
index 04c0e4d..b0d96d9 100644
--- a/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/BrokerFactoryHandler.java
+++ b/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/BrokerFactoryHandler.java
@@ -20,7 +20,7 @@ import org.apache.activemq.artemis.dto.BrokerDTO;
 
 import java.net.URI;
 
-public interface BrokerFactoryHandler
-{
+public interface BrokerFactoryHandler {
+
    BrokerDTO createBroker(URI brokerURI) throws Exception;
 }

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/bac96047/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/BrokerHandler.java
----------------------------------------------------------------------
diff --git a/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/BrokerHandler.java b/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/BrokerHandler.java
index 9f65a8e..3fe4027 100644
--- a/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/BrokerHandler.java
+++ b/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/BrokerHandler.java
@@ -20,7 +20,7 @@ import org.apache.activemq.artemis.dto.ServerDTO;
 import org.apache.activemq.artemis.integration.Broker;
 import org.apache.activemq.artemis.spi.core.security.ActiveMQSecurityManager;
 
-public interface BrokerHandler
-{
+public interface BrokerHandler {
+
    Broker createServer(ServerDTO brokerDTO, ActiveMQSecurityManager security);
 }

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/bac96047/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/FileBrokerHandler.java
----------------------------------------------------------------------
diff --git a/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/FileBrokerHandler.java b/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/FileBrokerHandler.java
index 75ac4f5..f6afc7f 100644
--- a/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/FileBrokerHandler.java
+++ b/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/FileBrokerHandler.java
@@ -21,11 +21,10 @@ import org.apache.activemq.artemis.integration.Broker;
 import org.apache.activemq.artemis.integration.FileBroker;
 import org.apache.activemq.artemis.spi.core.security.ActiveMQSecurityManager;
 
-public class FileBrokerHandler implements BrokerHandler
-{
+public class FileBrokerHandler implements BrokerHandler {
+
    @Override
-   public Broker createServer(ServerDTO brokerDTO, ActiveMQSecurityManager security)
-   {
+   public Broker createServer(ServerDTO brokerDTO, ActiveMQSecurityManager security) {
       return new FileBroker(brokerDTO, security);
    }
 }

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/bac96047/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/SecurityHandler.java
----------------------------------------------------------------------
diff --git a/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/SecurityHandler.java b/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/SecurityHandler.java
index 6eb6b0c..75768d0 100644
--- a/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/SecurityHandler.java
+++ b/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/SecurityHandler.java
@@ -19,7 +19,7 @@ package org.apache.activemq.artemis.factory;
 import org.apache.activemq.artemis.dto.SecurityDTO;
 import org.apache.activemq.artemis.spi.core.security.ActiveMQSecurityManager;
 
-public interface SecurityHandler
-{
+public interface SecurityHandler {
+
    ActiveMQSecurityManager createSecurityManager(SecurityDTO securityDTO) throws Exception;
 }

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/bac96047/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/SecurityManagerFactory.java
----------------------------------------------------------------------
diff --git a/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/SecurityManagerFactory.java b/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/SecurityManagerFactory.java
index 1453bd3..c422308 100644
--- a/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/SecurityManagerFactory.java
+++ b/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/SecurityManagerFactory.java
@@ -22,19 +22,15 @@ import org.apache.activemq.artemis.utils.FactoryFinder;
 
 import javax.xml.bind.annotation.XmlRootElement;
 
-public class SecurityManagerFactory
-{
+public class SecurityManagerFactory {
 
-   public static ActiveMQSecurityManager create(SecurityDTO config) throws Exception
-   {
-      if (config != null)
-      {
+   public static ActiveMQSecurityManager create(SecurityDTO config) throws Exception {
+      if (config != null) {
          FactoryFinder finder = new FactoryFinder("META-INF/services/org/apache/activemq/artemis/broker/security/");
-         SecurityHandler securityHandler = (SecurityHandler)finder.newInstance(config.getClass().getAnnotation(XmlRootElement.class).name());
+         SecurityHandler securityHandler = (SecurityHandler) finder.newInstance(config.getClass().getAnnotation(XmlRootElement.class).name());
          return securityHandler.createSecurityManager(config);
       }
-      else
-      {
+      else {
          throw new Exception("No security manager configured!");
       }
    }

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/bac96047/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/XmlBrokerFactoryHandler.java
----------------------------------------------------------------------
diff --git a/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/XmlBrokerFactoryHandler.java b/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/XmlBrokerFactoryHandler.java
index 11e195d..adbb041 100644
--- a/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/XmlBrokerFactoryHandler.java
+++ b/artemis-cli/src/main/java/org/apache/activemq/artemis/factory/XmlBrokerFactoryHandler.java
@@ -23,14 +23,12 @@ import org.apache.activemq.artemis.dto.XmlUtil;
 import java.io.File;
 import java.net.URI;
 
-public class XmlBrokerFactoryHandler implements BrokerFactoryHandler
-{
+public class XmlBrokerFactoryHandler implements BrokerFactoryHandler {
+
    @Override
-   public BrokerDTO createBroker(URI brokerURI) throws Exception
-   {
+   public BrokerDTO createBroker(URI brokerURI) throws Exception {
       File file = new File(brokerURI.getSchemeSpecificPart());
-      if (!file.exists())
-      {
+      if (!file.exists()) {
          throw new ConfigurationException("Invalid configuration URI, can't find file: " + file.getName());
       }
       return XmlUtil.decode(BrokerDTO.class, file);

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/bac96047/artemis-cli/src/main/java/org/apache/activemq/artemis/integration/Broker.java
----------------------------------------------------------------------
diff --git a/artemis-cli/src/main/java/org/apache/activemq/artemis/integration/Broker.java b/artemis-cli/src/main/java/org/apache/activemq/artemis/integration/Broker.java
index 8e1a4dc..306675f 100644
--- a/artemis-cli/src/main/java/org/apache/activemq/artemis/integration/Broker.java
+++ b/artemis-cli/src/main/java/org/apache/activemq/artemis/integration/Broker.java
@@ -21,6 +21,6 @@ import org.apache.activemq.artemis.core.server.ActiveMQComponent;
 /**
  * A Broker os a set of ActiveMQComponents that create a Server, for instance core and jms.
  */
-public interface Broker extends ActiveMQComponent
-{
+public interface Broker extends ActiveMQComponent {
+
 }

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/bac96047/artemis-cli/src/main/java/org/apache/activemq/artemis/integration/FileBroker.java
----------------------------------------------------------------------
diff --git a/artemis-cli/src/main/java/org/apache/activemq/artemis/integration/FileBroker.java b/artemis-cli/src/main/java/org/apache/activemq/artemis/integration/FileBroker.java
index ec5a44f..b66f6aa 100644
--- a/artemis-cli/src/main/java/org/apache/activemq/artemis/integration/FileBroker.java
+++ b/artemis-cli/src/main/java/org/apache/activemq/artemis/integration/FileBroker.java
@@ -28,8 +28,8 @@ import java.lang.management.ManagementFactory;
 import java.util.ArrayList;
 import java.util.Map;
 
-public class FileBroker implements Broker
-{
+public class FileBroker implements Broker {
+
    private final String configurationUrl;
 
    private boolean started;
@@ -38,17 +38,13 @@ public class FileBroker implements Broker
 
    private Map<String, ActiveMQComponent> components;
 
-   public FileBroker(ServerDTO broker, ActiveMQSecurityManager security)
-   {
+   public FileBroker(ServerDTO broker, ActiveMQSecurityManager security) {
       this.securityManager = security;
       this.configurationUrl = broker.configuration;
    }
 
-
-   public synchronized void start() throws Exception
-   {
-      if (started)
-      {
+   public synchronized void start() throws Exception {
+      if (started) {
          return;
       }
 
@@ -64,39 +60,32 @@ public class FileBroker implements Broker
 
       ArrayList<ActiveMQComponent> componentsByStartOrder = getComponentsByStartOrder(components);
       ActiveMQBootstrapLogger.LOGGER.serverStarting();
-      for (ActiveMQComponent component : componentsByStartOrder)
-      {
+      for (ActiveMQComponent component : componentsByStartOrder) {
          component.start();
       }
       started = true;
 
-
    }
 
    @Override
-   public void stop() throws Exception
-   {
-      if (!started)
-      {
+   public void stop() throws Exception {
+      if (!started) {
          return;
       }
       ActiveMQComponent[] mqComponents = new ActiveMQComponent[components.size()];
       components.values().toArray(mqComponents);
-      for (int i = mqComponents.length - 1; i >= 0; i--)
-      {
+      for (int i = mqComponents.length - 1; i >= 0; i--) {
          mqComponents[i].stop();
       }
       started = false;
    }
 
    @Override
-   public boolean isStarted()
-   {
+   public boolean isStarted() {
       return started;
    }
 
-   public Map<String, ActiveMQComponent> getComponents()
-   {
+   public Map<String, ActiveMQComponent> getComponents() {
       return components;
    }
 
@@ -104,12 +93,10 @@ public class FileBroker implements Broker
    * this makes sure the components are started in the correct order. Its simple at the mo as e only have core and jms but
    * will need impproving if we get more.
    * */
-   public ArrayList<ActiveMQComponent> getComponentsByStartOrder(Map<String, ActiveMQComponent> components)
-   {
+   public ArrayList<ActiveMQComponent> getComponentsByStartOrder(Map<String, ActiveMQComponent> components) {
       ArrayList<ActiveMQComponent> activeMQComponents = new ArrayList<ActiveMQComponent>();
       ActiveMQComponent jmsComponent = components.get("jms");
-      if (jmsComponent != null)
-      {
+      if (jmsComponent != null) {
          activeMQComponents.add(jmsComponent);
       }
       activeMQComponents.add(components.get("core"));

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/bac96047/artemis-cli/src/main/java/org/apache/activemq/artemis/integration/bootstrap/ActiveMQBootstrapBundle.java
----------------------------------------------------------------------
diff --git a/artemis-cli/src/main/java/org/apache/activemq/artemis/integration/bootstrap/ActiveMQBootstrapBundle.java b/artemis-cli/src/main/java/org/apache/activemq/artemis/integration/bootstrap/ActiveMQBootstrapBundle.java
index 5f31b01..5bb168c 100644
--- a/artemis-cli/src/main/java/org/apache/activemq/artemis/integration/bootstrap/ActiveMQBootstrapBundle.java
+++ b/artemis-cli/src/main/java/org/apache/activemq/artemis/integration/bootstrap/ActiveMQBootstrapBundle.java
@@ -16,7 +16,6 @@
  */
 package org.apache.activemq.artemis.integration.bootstrap;
 
-
 import org.jboss.logging.Messages;
 import org.jboss.logging.annotations.MessageBundle;
 
@@ -28,8 +27,8 @@ import org.jboss.logging.annotations.MessageBundle;
  * so 109000 to 109999
  */
 @MessageBundle(projectCode = "AMQ")
-public interface ActiveMQBootstrapBundle
-{
+public interface ActiveMQBootstrapBundle {
+
    ActiveMQBootstrapBundle BUNDLE = Messages.getBundle(ActiveMQBootstrapBundle.class);
 
 }

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/bac96047/artemis-cli/src/main/java/org/apache/activemq/artemis/integration/bootstrap/ActiveMQBootstrapLogger.java
----------------------------------------------------------------------
diff --git a/artemis-cli/src/main/java/org/apache/activemq/artemis/integration/bootstrap/ActiveMQBootstrapLogger.java b/artemis-cli/src/main/java/org/apache/activemq/artemis/integration/bootstrap/ActiveMQBootstrapLogger.java
index 3cd976f..1f7e6d9 100644
--- a/artemis-cli/src/main/java/org/apache/activemq/artemis/integration/bootstrap/ActiveMQBootstrapLogger.java
+++ b/artemis-cli/src/main/java/org/apache/activemq/artemis/integration/bootstrap/ActiveMQBootstrapLogger.java
@@ -38,8 +38,8 @@ import org.jboss.logging.annotations.MessageLogger;
  * so an INFO message would be 101000 to 101999
  */
 @MessageLogger(projectCode = "AMQ")
-public interface ActiveMQBootstrapLogger extends BasicLogger
-{
+public interface ActiveMQBootstrapLogger extends BasicLogger {
+
    /**
     * The default logger.
     */

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/bac96047/artemis-cli/src/main/java/org/apache/activemq/artemis/util/ServerUtil.java
----------------------------------------------------------------------
diff --git a/artemis-cli/src/main/java/org/apache/activemq/artemis/util/ServerUtil.java b/artemis-cli/src/main/java/org/apache/activemq/artemis/util/ServerUtil.java
index 9b384cd..6c4689e 100644
--- a/artemis-cli/src/main/java/org/apache/activemq/artemis/util/ServerUtil.java
+++ b/artemis-cli/src/main/java/org/apache/activemq/artemis/util/ServerUtil.java
@@ -33,68 +33,52 @@ import java.io.InputStream;
 import java.io.InputStreamReader;
 import java.util.HashMap;
 
-public class ServerUtil
-{
-   public static Process startServer(String artemisInstance, String serverName) throws Exception
-   {
+public class ServerUtil {
+
+   public static Process startServer(String artemisInstance, String serverName) throws Exception {
       return startServer(artemisInstance, serverName, 0, 0);
    }
 
-   public static Process startServer(String artemisInstance, String serverName, int id, int timeout) throws Exception
-   {
+   public static Process startServer(String artemisInstance, String serverName, int id, int timeout) throws Exception {
       boolean IS_WINDOWS = System.getProperty("os.name").toLowerCase().trim().startsWith("win");
 
       ProcessBuilder builder = null;
-      if (IS_WINDOWS)
-      {
+      if (IS_WINDOWS) {
          builder = new ProcessBuilder("cmd", "/c", "artemis.cmd", "run");
       }
-      else
-      {
+      else {
          builder = new ProcessBuilder("./artemis", "run");
       }
 
       builder.directory(new File(artemisInstance + "/bin"));
 
       final Process process = builder.start();
-      Runtime.getRuntime().addShutdownHook(new Thread()
-      {
-         public void run()
-         {
+      Runtime.getRuntime().addShutdownHook(new Thread() {
+         public void run() {
             process.destroy();
          }
       });
 
-      ProcessLogger outputLogger = new ProcessLogger(true,
-                                                     process.getInputStream(),
-                                                     serverName,
-                                                     false);
+      ProcessLogger outputLogger = new ProcessLogger(true, process.getInputStream(), serverName, false);
       outputLogger.start();
 
       // Adding a reader to System.err, so the VM won't hang on a System.err.println as identified on this forum thread:
       // http://www.jboss.org/index.html?module=bb&op=viewtopic&t=151815
-      ProcessLogger errorLogger = new ProcessLogger(true,
-                                                    process.getErrorStream(),
-                                                    serverName,
-                                                    true);
+      ProcessLogger errorLogger = new ProcessLogger(true, process.getErrorStream(), serverName, true);
       errorLogger.start();
 
       // wait for start
-      if (timeout != 0)
-      {
+      if (timeout != 0) {
          waitForServerToStart(id, timeout);
       }
 
       return process;
    }
 
-   public static void waitForServerToStart(int id, int timeout) throws InterruptedException
-   {
+   public static void waitForServerToStart(int id, int timeout) throws InterruptedException {
       long realTimeout = System.currentTimeMillis() + timeout;
-      while (System.currentTimeMillis() < realTimeout)
-      {
-         try
-         {
+      while (System.currentTimeMillis() < realTimeout) {
+         try {
             HashMap<String, Object> params = new HashMap<String, Object>();
             params.put("host", "localhost");
             params.put("port", 61616 + id);
@@ -103,8 +87,7 @@ public class ServerUtil
             cf.createConnection().close();
             System.out.println("server " + id + " started");
          }
-         catch (Exception e)
-         {
+         catch (Exception e) {
             System.out.println("awaiting server " + id + " start at " + (61616 + id));
             Thread.sleep(500);
             continue;
@@ -113,10 +96,8 @@ public class ServerUtil
       }
    }
 
-   public static void killServer(final Process server) throws Exception
-   {
-      if (server != null)
-      {
+   public static void killServer(final Process server) throws Exception {
+      if (server != null) {
          System.out.println("**********************************");
          System.out.println("Killing server " + server);
          System.out.println("**********************************");
@@ -126,35 +107,30 @@ public class ServerUtil
       }
    }
 
-   public static int getServer(Connection connection)
-   {
+   public static int getServer(Connection connection) {
       ClientSession session = ((ActiveMQConnection) connection).getInitialSession();
       TransportConfiguration transportConfiguration = session.getSessionFactory().getConnectorConfiguration();
       String port = (String) transportConfiguration.getParams().get("port");
       return Integer.valueOf(port) - 61616;
    }
 
-   public static  Connection getServerConnection(int server, Connection... connections)
-   {
-      for (Connection connection : connections)
-      {
+   public static Connection getServerConnection(int server, Connection... connections) {
+      for (Connection connection : connections) {
          ClientSession session = ((ActiveMQConnection) connection).getInitialSession();
          TransportConfiguration transportConfiguration = session.getSessionFactory().getConnectorConfiguration();
          String port = (String) transportConfiguration.getParams().get("port");
-         if (Integer.valueOf(port) == server + 61616)
-         {
+         if (Integer.valueOf(port) == server + 61616) {
             return connection;
          }
       }
       return null;
    }
 
-
    /**
     * Redirect the input stream to a logger (as debug logs)
     */
-   static class ProcessLogger extends Thread
-   {
+   static class ProcessLogger extends Thread {
+
       private final InputStream is;
 
       private final String logName;
@@ -166,8 +142,7 @@ public class ServerUtil
       ProcessLogger(final boolean print,
                     final InputStream is,
                     final String logName,
-                    final boolean sendToErr) throws ClassNotFoundException
-      {
+                    final boolean sendToErr) throws ClassNotFoundException {
          this.is = is;
          this.print = print;
          this.logName = logName;
@@ -176,30 +151,23 @@ public class ServerUtil
       }
 
       @Override
-      public void run()
-      {
-         try
-         {
+      public void run() {
+         try {
             InputStreamReader isr = new InputStreamReader(is);
             BufferedReader br = new BufferedReader(isr);
             String line;
-            while ((line = br.readLine()) != null)
-            {
-               if (print)
-               {
-                  if (sendToErr)
-                  {
+            while ((line = br.readLine()) != null) {
+               if (print) {
+                  if (sendToErr) {
                      System.err.println(logName + "-err:" + line);
                   }
-                  else
-                  {
+                  else {
                      System.out.println(logName + "-out:" + line);
                   }
                }
             }
          }
-         catch (IOException e)
-         {
+         catch (IOException e) {
             // ok, stream closed
          }
       }

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/bac96047/artemis-cli/src/test/java/org/apache/activemq/cli/test/ArtemisTest.java
----------------------------------------------------------------------
diff --git a/artemis-cli/src/test/java/org/apache/activemq/cli/test/ArtemisTest.java b/artemis-cli/src/test/java/org/apache/activemq/cli/test/ArtemisTest.java
index a42fae9..cfcc53f 100644
--- a/artemis-cli/src/test/java/org/apache/activemq/cli/test/ArtemisTest.java
+++ b/artemis-cli/src/test/java/org/apache/activemq/cli/test/ArtemisTest.java
@@ -43,41 +43,35 @@ import org.junit.rules.TemporaryFolder;
 /**
  * Test to validate that the CLI doesn't throw improper exceptions when invoked.
  */
-public class ArtemisTest
-{
+public class ArtemisTest {
+
    @Rule
    public TemporaryFolder temporaryFolder;
 
-   public ArtemisTest()
-   {
+   public ArtemisTest() {
       File parent = new File("./target/tmp");
       parent.mkdirs();
       temporaryFolder = new TemporaryFolder(parent);
    }
 
-
    @After
-   public void cleanup()
-   {
+   public void cleanup() {
       System.clearProperty("artemis.instance");
       Run.setEmbedded(false);
    }
 
    @Test
-   public void invalidCliDoesntThrowException()
-   {
+   public void invalidCliDoesntThrowException() {
       testCli("create");
    }
 
    @Test
-   public void invalidPathDoesntThrowException()
-   {
-      testCli("create","/rawr");
+   public void invalidPathDoesntThrowException() {
+      testCli("create", "/rawr");
    }
 
    @Test
-   public void testSync() throws Exception
-   {
+   public void testSync() throws Exception {
       int writes = 2560;
       int tries = 10;
       long totalAvg = SyncCalculation.syncTest(temporaryFolder.getRoot(), 4096, writes, tries, true, true);
@@ -88,9 +82,9 @@ public class ArtemisTest
       Assert.assertEquals(0, LibaioContext.getTotalMaxIO());
 
    }
+
    @Test
-   public void testSimpleRun() throws Exception
-   {
+   public void testSimpleRun() throws Exception {
       String queues = "q1,t2";
       String topics = "t1,t2";
       Run.setEmbedded(true);
@@ -99,24 +93,19 @@ public class ArtemisTest
       // Some exceptions may happen on the initialization, but they should be ok on start the basic core protocol
       Artemis.execute("run");
 
-
       try (ServerLocator locator = ServerLocatorImpl.newLocator("tcp://localhost:61616");
            ClientSessionFactory factory = locator.createSessionFactory();
-           ClientSession coreSession = factory.createSession())
-      {
-         for (String str: queues.split(","))
-         {
+           ClientSession coreSession = factory.createSession()) {
+         for (String str : queues.split(",")) {
             ClientSession.QueueQuery queryResult = coreSession.queueQuery(SimpleString.toSimpleString("jms.queue." + str));
             Assert.assertTrue("Couldn't find queue " + str, queryResult.isExists());
          }
-         for (String str: topics.split(","))
-         {
+         for (String str : topics.split(",")) {
             ClientSession.QueueQuery queryResult = coreSession.queueQuery(SimpleString.toSimpleString("jms.topic." + str));
             Assert.assertTrue("Couldn't find topic " + str, queryResult.isExists());
          }
       }
 
-
       Assert.assertEquals(Integer.valueOf(1000), Artemis.execute("producer", "--message-count", "1000", "--verbose"));
       Assert.assertEquals(Integer.valueOf(1000), Artemis.execute("consumer", "--verbose", "--break-on-null", "--receive-timeout", "100"));
 
@@ -125,13 +114,11 @@ public class ArtemisTest
       Session session = connection.createSession(true, Session.SESSION_TRANSACTED);
       MessageProducer producer = session.createProducer(ActiveMQDestination.createDestination("queue://TEST", ActiveMQDestination.QUEUE_TYPE));
 
-
       TextMessage message = session.createTextMessage("Banana");
       message.setStringProperty("fruit", "banana");
       producer.send(message);
 
-      for (int i = 0; i < 100; i++)
-      {
+      for (int i = 0; i < 100; i++) {
          message = session.createTextMessage("orange");
          message.setStringProperty("fruit", "orange");
          producer.send(message);
@@ -154,7 +141,7 @@ public class ArtemisTest
       Assert.assertEquals(Integer.valueOf(1), Artemis.execute("consumer", "--txt-size", "50", "--verbose", "--break-on-null", "--receive-timeout", "100", "--filter", "fruit='banana'"));
 
       // Checking it was acked before
-      Assert.assertEquals(Integer.valueOf(100), Artemis.execute("consumer", "--txt-size", "50", "--verbose",  "--break-on-null", "--receive-timeout", "100"));
+      Assert.assertEquals(Integer.valueOf(100), Artemis.execute("consumer", "--txt-size", "50", "--verbose", "--break-on-null", "--receive-timeout", "100"));
 
       Artemis.execute("stop");
       Assert.assertTrue(Run.latchRunning.await(5, TimeUnit.SECONDS));
@@ -162,14 +149,11 @@ public class ArtemisTest
 
    }
 
-   private void testCli(String... args)
-   {
-      try
-      {
+   private void testCli(String... args) {
+      try {
          Artemis.main(args);
       }
-      catch (Exception e)
-      {
+      catch (Exception e) {
          e.printStackTrace();
          Assert.fail("Exception caught " + e.getMessage());
       }

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/bac96047/artemis-cli/src/test/java/org/apache/activemq/cli/test/FileBrokerTest.java
----------------------------------------------------------------------
diff --git a/artemis-cli/src/test/java/org/apache/activemq/cli/test/FileBrokerTest.java b/artemis-cli/src/test/java/org/apache/activemq/cli/test/FileBrokerTest.java
index 5d86f6e..c796f3f 100644
--- a/artemis-cli/src/test/java/org/apache/activemq/cli/test/FileBrokerTest.java
+++ b/artemis-cli/src/test/java/org/apache/activemq/cli/test/FileBrokerTest.java
@@ -24,16 +24,14 @@ import org.apache.activemq.artemis.spi.core.security.ActiveMQSecurityManagerImpl
 import org.junit.Assert;
 import org.junit.Test;
 
-public class FileBrokerTest
-{
+public class FileBrokerTest {
+
    @Test
-   public void startWithJMS() throws Exception
-   {
+   public void startWithJMS() throws Exception {
       ServerDTO serverDTO = new ServerDTO();
       serverDTO.configuration = "broker.xml";
       FileBroker broker = null;
-      try
-      {
+      try {
          broker = new FileBroker(serverDTO, new ActiveMQSecurityManagerImpl());
          broker.start();
          JMSServerManagerImpl jmsServerManager = (JMSServerManagerImpl) broker.getComponents().get("jms");
@@ -46,23 +44,19 @@ public class FileBrokerTest
          Assert.assertTrue(activeMQServer.isStarted());
          Assert.assertTrue(broker.isStarted());
       }
-      finally
-      {
-         if (broker != null)
-         {
+      finally {
+         if (broker != null) {
             broker.stop();
          }
       }
    }
 
    @Test
-   public void startWithoutJMS() throws Exception
-   {
+   public void startWithoutJMS() throws Exception {
       ServerDTO serverDTO = new ServerDTO();
       serverDTO.configuration = "broker-nojms.xml";
       FileBroker broker = null;
-      try
-      {
+      try {
          broker = new FileBroker(serverDTO, new ActiveMQSecurityManagerImpl());
          broker.start();
          JMSServerManagerImpl jmsServerManager = (JMSServerManagerImpl) broker.getComponents().get("jms");
@@ -72,8 +66,7 @@ public class FileBrokerTest
          Assert.assertTrue(activeMQServer.isStarted());
          Assert.assertTrue(broker.isStarted());
       }
-      finally
-      {
+      finally {
          assert broker != null;
          broker.stop();
       }

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/bac96047/artemis-cli/src/test/java/org/apache/activemq/cli/test/StreamClassPathTest.java
----------------------------------------------------------------------
diff --git a/artemis-cli/src/test/java/org/apache/activemq/cli/test/StreamClassPathTest.java b/artemis-cli/src/test/java/org/apache/activemq/cli/test/StreamClassPathTest.java
index 0ee3afb..21579dc 100644
--- a/artemis-cli/src/test/java/org/apache/activemq/cli/test/StreamClassPathTest.java
+++ b/artemis-cli/src/test/java/org/apache/activemq/cli/test/StreamClassPathTest.java
@@ -23,13 +23,13 @@ import org.apache.activemq.artemis.cli.commands.Create;
 import org.junit.Assert;
 import org.junit.Test;
 
-public class StreamClassPathTest
-{
+public class StreamClassPathTest {
 
-   /** Validate if all the known resources are available on the classpath for the jar */
+   /**
+    * Validate if all the known resources are available on the classpath for the jar
+    */
    @Test
-   public void testFindStreams() throws Exception
-   {
+   public void testFindStreams() throws Exception {
       openStream(Create.BIN_ARTEMIS_CMD);
       openStream(Create.BIN_ARTEMIS_SERVICE_EXE);
       openStream(Create.BIN_ARTEMIS_SERVICE_XML);
@@ -52,9 +52,7 @@ public class StreamClassPathTest
       openStream(Create.ETC_JOURNAL_BUFFER_SETTINGS);
    }
 
-
-   private void openStream(String source) throws Exception
-   {
+   private void openStream(String source) throws Exception {
       Create create = new Create();
       InputStream in = create.openStream(source);
       Assert.assertNotNull(source + " not found", in);

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/bac96047/artemis-commons/src/main/java/org/apache/activemq/artemis/api/core/ActiveMQAddressExistsException.java
----------------------------------------------------------------------
diff --git a/artemis-commons/src/main/java/org/apache/activemq/artemis/api/core/ActiveMQAddressExistsException.java b/artemis-commons/src/main/java/org/apache/activemq/artemis/api/core/ActiveMQAddressExistsException.java
index aeec7a8..9477bb8 100644
--- a/artemis-commons/src/main/java/org/apache/activemq/artemis/api/core/ActiveMQAddressExistsException.java
+++ b/artemis-commons/src/main/java/org/apache/activemq/artemis/api/core/ActiveMQAddressExistsException.java
@@ -19,17 +19,15 @@ package org.apache.activemq.artemis.api.core;
 /**
  * An operation failed because an address exists on the server.
  */
-public final class ActiveMQAddressExistsException extends ActiveMQException
-{
+public final class ActiveMQAddressExistsException extends ActiveMQException {
+
    private static final long serialVersionUID = 3032730450033992367L;
 
-   public ActiveMQAddressExistsException()
-   {
+   public ActiveMQAddressExistsException() {
       super(ActiveMQExceptionType.ADDRESS_EXISTS);
    }
 
-   public ActiveMQAddressExistsException(String msg)
-   {
+   public ActiveMQAddressExistsException(String msg) {
       super(ActiveMQExceptionType.ADDRESS_EXISTS, msg);
    }
 }

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/bac96047/artemis-commons/src/main/java/org/apache/activemq/artemis/api/core/ActiveMQAddressFullException.java
----------------------------------------------------------------------
diff --git a/artemis-commons/src/main/java/org/apache/activemq/artemis/api/core/ActiveMQAddressFullException.java b/artemis-commons/src/main/java/org/apache/activemq/artemis/api/core/ActiveMQAddressFullException.java
index c8cbe45..1cd5b63 100644
--- a/artemis-commons/src/main/java/org/apache/activemq/artemis/api/core/ActiveMQAddressFullException.java
+++ b/artemis-commons/src/main/java/org/apache/activemq/artemis/api/core/ActiveMQAddressFullException.java
@@ -19,17 +19,15 @@ package org.apache.activemq.artemis.api.core;
 /**
  * An address is full.
  */
-public final class ActiveMQAddressFullException extends ActiveMQException
-{
+public final class ActiveMQAddressFullException extends ActiveMQException {
+
    private static final long serialVersionUID = 0;
 
-   public ActiveMQAddressFullException(String message)
-   {
+   public ActiveMQAddressFullException(String message) {
       super(ActiveMQExceptionType.ADDRESS_FULL, message);
    }
 
-   public ActiveMQAddressFullException()
-   {
+   public ActiveMQAddressFullException() {
       super(ActiveMQExceptionType.ADDRESS_FULL);
    }
 }

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/bac96047/artemis-commons/src/main/java/org/apache/activemq/artemis/api/core/ActiveMQAlreadyReplicatingException.java
----------------------------------------------------------------------
diff --git a/artemis-commons/src/main/java/org/apache/activemq/artemis/api/core/ActiveMQAlreadyReplicatingException.java b/artemis-commons/src/main/java/org/apache/activemq/artemis/api/core/ActiveMQAlreadyReplicatingException.java
index 125c492..dd3348c 100644
--- a/artemis-commons/src/main/java/org/apache/activemq/artemis/api/core/ActiveMQAlreadyReplicatingException.java
+++ b/artemis-commons/src/main/java/org/apache/activemq/artemis/api/core/ActiveMQAlreadyReplicatingException.java
@@ -19,17 +19,15 @@ package org.apache.activemq.artemis.api.core;
 /**
  * The server is already paired with a replicating backup.
  */
-public final class ActiveMQAlreadyReplicatingException extends ActiveMQException
-{
+public final class ActiveMQAlreadyReplicatingException extends ActiveMQException {
+
    private static final long serialVersionUID = -7352538521961996152L;
 
-   public ActiveMQAlreadyReplicatingException()
-   {
+   public ActiveMQAlreadyReplicatingException() {
       super(ActiveMQExceptionType.ALREADY_REPLICATING);
    }
 
-   public ActiveMQAlreadyReplicatingException(String msg)
-   {
+   public ActiveMQAlreadyReplicatingException(String msg) {
       super(ActiveMQExceptionType.ALREADY_REPLICATING, msg);
    }
 }

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/bac96047/artemis-commons/src/main/java/org/apache/activemq/artemis/api/core/ActiveMQBuffer.java
----------------------------------------------------------------------
diff --git a/artemis-commons/src/main/java/org/apache/activemq/artemis/api/core/ActiveMQBuffer.java b/artemis-commons/src/main/java/org/apache/activemq/artemis/api/core/ActiveMQBuffer.java
index 63d956c..12dd09f 100644
--- a/artemis-commons/src/main/java/org/apache/activemq/artemis/api/core/ActiveMQBuffer.java
+++ b/artemis-commons/src/main/java/org/apache/activemq/artemis/api/core/ActiveMQBuffer.java
@@ -26,10 +26,11 @@ import io.netty.buffer.ByteBuf;
  * Instances of it can be obtained from {@link ActiveMQBuffers} factory.
  * <p>
  * Much of it derived from Netty ChannelBuffer by Trustin Lee
+ *
  * @see ActiveMQBuffers
  */
-public interface ActiveMQBuffer
-{
+public interface ActiveMQBuffer {
+
    /**
     * Returns the underlying Netty's ByteBuf
     *
@@ -52,11 +53,10 @@ public interface ActiveMQBuffer
    /**
     * Sets the {@code readerIndex} of this buffer.
     *
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code readerIndex} is
-    *            less than {@code 0} or
-    *            greater than {@code this.writerIndex}
     * @param readerIndex The reader's index The reader infex
+    * @throws IndexOutOfBoundsException if the specified {@code readerIndex} is
+    *                                   less than {@code 0} or
+    *                                   greater than {@code this.writerIndex}
     */
    void readerIndex(int readerIndex);
 
@@ -69,10 +69,9 @@ public interface ActiveMQBuffer
     * Sets the {@code writerIndex} of this buffer.
     *
     * @param writerIndex The writer's index
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code writerIndex} is
-    *            less than {@code this.readerIndex} or
-    *            greater than {@code this.capacity}
+    * @throws IndexOutOfBoundsException if the specified {@code writerIndex} is
+    *                                   less than {@code this.readerIndex} or
+    *                                   greater than {@code this.capacity}
     */
    void writerIndex(int writerIndex);
 
@@ -123,11 +122,10 @@ public interface ActiveMQBuffer
     *
     * @param readerIndex The reader's index
     * @param writerIndex The writer's index
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code readerIndex} is less than 0,
-    *         if the specified {@code writerIndex} is less than the specified
-    *         {@code readerIndex} or if the specified {@code writerIndex} is
-    *         greater than {@code this.capacity}
+    * @throws IndexOutOfBoundsException if the specified {@code readerIndex} is less than 0,
+    *                                   if the specified {@code writerIndex} is less than the specified
+    *                                   {@code readerIndex} or if the specified {@code writerIndex} is
+    *                                   greater than {@code this.capacity}
     */
    void setIndex(int readerIndex, int writerIndex);
 
@@ -174,9 +172,8 @@ public interface ActiveMQBuffer
     * Repositions the current {@code readerIndex} to the marked
     * {@code readerIndex} in this buffer.
     *
-    * @throws IndexOutOfBoundsException
-    *         if the current {@code writerIndex} is less than the marked
-    *         {@code readerIndex}
+    * @throws IndexOutOfBoundsException if the current {@code writerIndex} is less than the marked
+    *                                   {@code readerIndex}
     */
    void resetReaderIndex();
 
@@ -192,9 +189,8 @@ public interface ActiveMQBuffer
     * Repositions the current {@code writerIndex} to the marked
     * {@code writerIndex} in this buffer.
     *
-    * @throws IndexOutOfBoundsException
-    *         if the current {@code readerIndex} is greater than the marked
-    *         {@code writerIndex}
+    * @throws IndexOutOfBoundsException if the current {@code readerIndex} is greater than the marked
+    *                                   {@code writerIndex}
     */
    void resetWriterIndex();
 
@@ -215,11 +211,10 @@ public interface ActiveMQBuffer
     *
     * @param index Index into the buffer
     * @return The byte at the specified index
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0} or
-    *         {@code index + 1} is greater than {@code this.capacity}
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0} or
+    *                                   {@code index + 1} is greater than {@code this.capacity}
     */
-   byte  getByte(int index);
+   byte getByte(int index);
 
    /**
     * Gets an unsigned byte at the specified absolute {@code index} in this
@@ -228,9 +223,8 @@ public interface ActiveMQBuffer
     *
     * @param index Index into the buffer
     * @return an unsigned byte at the specified absolute {@code index}
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0} or
-    *         {@code index + 1} is greater than {@code this.capacity}
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0} or
+    *                                   {@code index + 1} is greater than {@code this.capacity}
     */
    short getUnsignedByte(int index);
 
@@ -241,9 +235,8 @@ public interface ActiveMQBuffer
     *
     * @param index Index into the buffer
     * @return a 16-bit short integer at the specified absolute {@code index}
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0} or
-    *         {@code index + 2} is greater than {@code this.capacity}
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0} or
+    *                                   {@code index + 2} is greater than {@code this.capacity}
     */
    short getShort(int index);
 
@@ -254,9 +247,8 @@ public interface ActiveMQBuffer
     *
     * @param index Index into the buffer
     * @return an unsigned 16-bit short integer
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0} or
-    *         {@code index + 2} is greater than {@code this.capacity}
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0} or
+    *                                   {@code index + 2} is greater than {@code this.capacity}
     */
    int getUnsignedShort(int index);
 
@@ -267,11 +259,10 @@ public interface ActiveMQBuffer
     *
     * @param index Index into the buffer
     * @return a 32-bit integer at the specified absolute {@code index}
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0} or
-    *         {@code index + 4} is greater than {@code this.capacity}
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0} or
+    *                                   {@code index + 4} is greater than {@code this.capacity}
     */
-   int   getInt(int index);
+   int getInt(int index);
 
    /**
     * Gets an unsigned 32-bit integer at the specified absolute {@code index}
@@ -280,11 +271,10 @@ public interface ActiveMQBuffer
     *
     * @param index The index into this buffer
     * @return an unsigned 32-bit integer at the specified absolute {@code index}
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0} or
-    *         {@code index + 4} is greater than {@code this.capacity}
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0} or
+    *                                   {@code index + 4} is greater than {@code this.capacity}
     */
-   long  getUnsignedInt(int index);
+   long getUnsignedInt(int index);
 
    /**
     * Gets a 64-bit long integer at the specified absolute {@code index} in
@@ -293,11 +283,10 @@ public interface ActiveMQBuffer
     *
     * @param index Index into the buffer
     * @return a 64-bit long integer at the specified absolute {@code index}
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0} or
-    *         {@code index + 8} is greater than {@code this.capacity}
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0} or
+    *                                   {@code index + 8} is greater than {@code this.capacity}
     */
-   long  getLong(int index);
+   long getLong(int index);
 
    /**
     * Transfers this buffer's data to the specified destination starting at
@@ -311,11 +300,10 @@ public interface ActiveMQBuffer
     * the source buffer (i.e. {@code this}).
     *
     * @param index Index into the buffer
-    * @param dst The destination buffer
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0} or
-    *         if {@code index + dst.writableBytes} is greater than
-    *            {@code this.capacity}
+    * @param dst   The destination buffer
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0} or
+    *                                   if {@code index + dst.writableBytes} is greater than
+    *                                   {@code this.capacity}
     */
    void getBytes(int index, ActiveMQBuffer dst);
 
@@ -330,13 +318,12 @@ public interface ActiveMQBuffer
     * the source buffer (i.e. {@code this}).
     *
     * @param length the number of bytes to transfer
-    * @param index Index into the buffer
-    * @param dst The destination buffer
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0},
-    *         if {@code index + length} is greater than
-    *            {@code this.capacity}, or
-    *         if {@code length} is greater than {@code dst.writableBytes}
+    * @param index  Index into the buffer
+    * @param dst    The destination buffer
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0},
+    *                                   if {@code index + length} is greater than
+    *                                   {@code this.capacity}, or
+    *                                   if {@code length} is greater than {@code dst.writableBytes}
     */
    void getBytes(int index, ActiveMQBuffer dst, int length);
 
@@ -346,18 +333,16 @@ public interface ActiveMQBuffer
     * This method does not modify {@code readerIndex} or {@code writerIndex}
     * of both the source (i.e. {@code this}) and the destination.
     *
-    * @param dst The destination bufferIndex the first index of the destination
-    * @param length  The number of bytes to transfer
-    * @param index Index into the buffer
+    * @param dst      The destination bufferIndex the first index of the destination
+    * @param length   The number of bytes to transfer
+    * @param index    Index into the buffer
     * @param dstIndex The index into the destination bufferThe destination buffer
-    *
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0},
-    *         if the specified {@code dstIndex} is less than {@code 0},
-    *         if {@code index + length} is greater than
-    *            {@code this.capacity}, or
-    *         if {@code dstIndex + length} is greater than
-    *            {@code dst.capacity}
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0},
+    *                                   if the specified {@code dstIndex} is less than {@code 0},
+    *                                   if {@code index + length} is greater than
+    *                                   {@code this.capacity}, or
+    *                                   if {@code dstIndex + length} is greater than
+    *                                   {@code dst.capacity}
     */
    void getBytes(int index, ActiveMQBuffer dst, int dstIndex, int length);
 
@@ -368,11 +353,10 @@ public interface ActiveMQBuffer
     * this buffer
     *
     * @param index Index into the buffer
-    * @param dst The destination buffer
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0} or
-    *         if {@code index + dst.length} is greater than
-    *            {@code this.capacity}
+    * @param dst   The destination buffer
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0} or
+    *                                   if {@code index + dst.length} is greater than
+    *                                   {@code this.capacity}
     */
    void getBytes(int index, byte[] dst);
 
@@ -384,16 +368,14 @@ public interface ActiveMQBuffer
     *
     * @param dstIndex The first index of the destination
     * @param length   The number of bytes to transfer
-    * @param index Index into the buffer
-    * @param dst The destination buffer
-    *
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0},
-    *         if the specified {@code dstIndex} is less than {@code 0},
-    *         if {@code index + length} is greater than
-    *            {@code this.capacity}, or
-    *         if {@code dstIndex + length} is greater than
-    *            {@code dst.length}
+    * @param index    Index into the buffer
+    * @param dst      The destination buffer
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0},
+    *                                   if the specified {@code dstIndex} is less than {@code 0},
+    *                                   if {@code index + length} is greater than
+    *                                   {@code this.capacity}, or
+    *                                   if {@code dstIndex + length} is greater than
+    *                                   {@code dst.length}
     */
    void getBytes(int index, byte[] dst, int dstIndex, int length);
 
@@ -405,11 +387,10 @@ public interface ActiveMQBuffer
     * this buffer while the destination's {@code position} will be increased.
     *
     * @param index Index into the buffer
-    * @param dst The destination buffer
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0} or
-    *         if {@code index + dst.remaining()} is greater than
-    *            {@code this.capacity}
+    * @param dst   The destination buffer
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0} or
+    *                                   if {@code index + dst.remaining()} is greater than
+    *                                   {@code this.capacity}
     */
    void getBytes(int index, ByteBuffer dst);
 
@@ -420,9 +401,8 @@ public interface ActiveMQBuffer
     *
     * @param index Index into the buffer
     * @return a char at the specified absolute {@code index}
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0} or
-    *         {@code index + 2} is greater than {@code this.capacity}
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0} or
+    *                                   {@code index + 2} is greater than {@code this.capacity}
     */
    char getChar(int index);
 
@@ -433,9 +413,8 @@ public interface ActiveMQBuffer
     *
     * @param index Index into the buffer
     * @return a float at the specified absolute {@code index}
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0} or
-    *         {@code index + 4} is greater than {@code this.capacity}
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0} or
+    *                                   {@code index + 4} is greater than {@code this.capacity}
     */
    float getFloat(int index);
 
@@ -446,9 +425,8 @@ public interface ActiveMQBuffer
     *
     * @param index Index into the buffer
     * @return a double at the specified absolute {@code index}
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0} or
-    *         {@code index + 8} is greater than {@code this.capacity}
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0} or
+    *                                   {@code index + 8} is greater than {@code this.capacity}
     */
    double getDouble(int index);
 
@@ -460,9 +438,8 @@ public interface ActiveMQBuffer
     *
     * @param index Index into the buffer
     * @param value The specified byte
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0} or
-    *         {@code index + 1} is greater than {@code this.capacity}
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0} or
+    *                                   {@code index + 1} is greater than {@code this.capacity}
     */
    void setByte(int index, byte value);
 
@@ -474,9 +451,8 @@ public interface ActiveMQBuffer
     *
     * @param index Index into the buffer
     * @param value The specified 16-bit short integer
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0} or
-    *         {@code index + 2} is greater than {@code this.capacity}
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0} or
+    *                                   {@code index + 2} is greater than {@code this.capacity}
     */
    void setShort(int index, short value);
 
@@ -488,9 +464,8 @@ public interface ActiveMQBuffer
     *
     * @param index Index into the buffer
     * @param value The specified 32-bit integer
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0} or
-    *         {@code index + 4} is greater than {@code this.capacity}
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0} or
+    *                                   {@code index + 4} is greater than {@code this.capacity}
     */
    void setInt(int index, int value);
 
@@ -502,9 +477,8 @@ public interface ActiveMQBuffer
     *
     * @param index Index into the buffer
     * @param value The specified 64-bit long integer
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0} or
-    *         {@code index + 8} is greater than {@code this.capacity}
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0} or
+    *                                   {@code index + 8} is greater than {@code this.capacity}
     */
    void setLong(int index, long value);
 
@@ -520,11 +494,10 @@ public interface ActiveMQBuffer
     * the source buffer (i.e. {@code this}).
     *
     * @param index Index into the buffer
-    * @param src The source buffer
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0} or
-    *         if {@code index + src.readableBytes} is greater than
-    *            {@code this.capacity}
+    * @param src   The source buffer
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0} or
+    *                                   if {@code index + src.readableBytes} is greater than
+    *                                   {@code this.capacity}
     */
    void setBytes(int index, ActiveMQBuffer src);
 
@@ -539,14 +512,12 @@ public interface ActiveMQBuffer
     * the source buffer (i.e. {@code this}).
     *
     * @param length the number of bytes to transfer
-    * @param index Index into the buffer
-    * @param src The source buffer
-    *
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0},
-    *         if {@code index + length} is greater than
-    *            {@code this.capacity}, or
-    *         if {@code length} is greater than {@code src.readableBytes}
+    * @param index  Index into the buffer
+    * @param src    The source buffer
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0},
+    *                                   if {@code index + length} is greater than
+    *                                   {@code this.capacity}, or
+    *                                   if {@code length} is greater than {@code src.readableBytes}
     */
    void setBytes(int index, ActiveMQBuffer src, int length);
 
@@ -556,18 +527,16 @@ public interface ActiveMQBuffer
     * This method does not modify {@code readerIndex} or {@code writerIndex}
     * of both the source (i.e. {@code this}) and the destination.
     *
-    * @param src The source bufferIndex the first index of the source
-    * @param length  The number of bytes to transfer
-    * @param index Index into the buffer
+    * @param src      The source bufferIndex the first index of the source
+    * @param length   The number of bytes to transfer
+    * @param index    Index into the buffer
     * @param srcIndex The source buffer index
-    *
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0},
-    *         if the specified {@code srcIndex} is less than {@code 0},
-    *         if {@code index + length} is greater than
-    *            {@code this.capacity}, or
-    *         if {@code srcIndex + length} is greater than
-    *            {@code src.capacity}
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0},
+    *                                   if the specified {@code srcIndex} is less than {@code 0},
+    *                                   if {@code index + length} is greater than
+    *                                   {@code this.capacity}, or
+    *                                   if {@code srcIndex + length} is greater than
+    *                                   {@code src.capacity}
     */
    void setBytes(int index, ActiveMQBuffer src, int srcIndex, int length);
 
@@ -578,11 +547,10 @@ public interface ActiveMQBuffer
     * this buffer.
     *
     * @param index Index into the buffer
-    * @param src The source buffer
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0} or
-    *         if {@code index + src.length} is greater than
-    *            {@code this.capacity}
+    * @param src   The source buffer
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0} or
+    *                                   if {@code index + src.length} is greater than
+    *                                   {@code this.capacity}
     */
    void setBytes(int index, byte[] src);
 
@@ -592,17 +560,15 @@ public interface ActiveMQBuffer
     * This method does not modify {@code readerIndex} or {@code writerIndex} of
     * this buffer.
     *
-    * @param index Index into the buffer
-    * @param src The source buffer
+    * @param index    Index into the buffer
+    * @param src      The source buffer
     * @param srcIndex The source buffer index
-    * @param length The number of bytes to transfer
-    *
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0},
-    *         if the specified {@code srcIndex} is less than {@code 0},
-    *         if {@code index + length} is greater than
-    *            {@code this.capacity}, or
-    *         if {@code srcIndex + length} is greater than {@code src.length}
+    * @param length   The number of bytes to transfer
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0},
+    *                                   if the specified {@code srcIndex} is less than {@code 0},
+    *                                   if {@code index + length} is greater than
+    *                                   {@code this.capacity}, or
+    *                                   if {@code srcIndex + length} is greater than {@code src.length}
     */
    void setBytes(int index, byte[] src, int srcIndex, int length);
 
@@ -614,11 +580,10 @@ public interface ActiveMQBuffer
     * this buffer.
     *
     * @param index Index into the buffer
-    * @param src The source buffer
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0} or
-    *         if {@code index + src.remaining()} is greater than
-    *            {@code this.capacity}
+    * @param src   The source buffer
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0} or
+    *                                   if {@code index + src.remaining()} is greater than
+    *                                   {@code this.capacity}
     */
    void setBytes(int index, ByteBuffer src);
 
@@ -630,9 +595,8 @@ public interface ActiveMQBuffer
     *
     * @param index Index into the buffer
     * @param value The specified char
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0} or
-    *         {@code index + 2} is greater than {@code this.capacity}
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0} or
+    *                                   {@code index + 2} is greater than {@code this.capacity}
     */
    void setChar(int index, char value);
 
@@ -644,9 +608,8 @@ public interface ActiveMQBuffer
     *
     * @param index Index into the buffer
     * @param value The specified float
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0} or
-    *         {@code index + 4} is greater than {@code this.capacity}
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0} or
+    *                                   {@code index + 4} is greater than {@code this.capacity}
     */
    void setFloat(int index, float value);
 
@@ -658,9 +621,8 @@ public interface ActiveMQBuffer
     *
     * @param index Index into the buffer
     * @param value The specified double
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code index} is less than {@code 0} or
-    *         {@code index + 8} is greater than {@code this.capacity}
+    * @throws IndexOutOfBoundsException if the specified {@code index} is less than {@code 0} or
+    *                                   {@code index + 8} is greater than {@code this.capacity}
     */
    void setDouble(int index, double value);
 
@@ -669,8 +631,7 @@ public interface ActiveMQBuffer
     * the {@code readerIndex} by {@code 1} in this buffer.
     *
     * @return a byte at the current {@code readerIndex}
-    * @throws IndexOutOfBoundsException
-    *         if {@code this.readableBytes} is less than {@code 1}
+    * @throws IndexOutOfBoundsException if {@code this.readableBytes} is less than {@code 1}
     */
    byte readByte();
 
@@ -679,8 +640,7 @@ public interface ActiveMQBuffer
     * the {@code readerIndex} by {@code 1} in this buffer.
     *
     * @return an unsigned byte at the current {@code readerIndex}
-    * @throws IndexOutOfBoundsException
-    *         if {@code this.readableBytes} is less than {@code 1}
+    * @throws IndexOutOfBoundsException if {@code this.readableBytes} is less than {@code 1}
     */
    short readUnsignedByte();
 
@@ -689,8 +649,7 @@ public interface ActiveMQBuffer
     * and increases the {@code readerIndex} by {@code 2} in this buffer.
     *
     * @return a 16-bit short integer at the current {@code readerIndex}
-    * @throws IndexOutOfBoundsException
-    *         if {@code this.readableBytes} is less than {@code 2}
+    * @throws IndexOutOfBoundsException if {@code this.readableBytes} is less than {@code 2}
     */
    short readShort();
 
@@ -699,48 +658,43 @@ public interface ActiveMQBuffer
     * and increases the {@code readerIndex} by {@code 2} in this buffer.
     *
     * @return an unsigned 16-bit short integer at the current {@code readerIndex}
-    * @throws IndexOutOfBoundsException
-    *         if {@code this.readableBytes} is less than {@code 2}
+    * @throws IndexOutOfBoundsException if {@code this.readableBytes} is less than {@code 2}
     */
-   int   readUnsignedShort();
+   int readUnsignedShort();
 
    /**
     * Gets a 32-bit integer at the current {@code readerIndex}
     * and increases the {@code readerIndex} by {@code 4} in this buffer.
     *
     * @return a 32-bit integer at the current {@code readerIndex}
-    * @throws IndexOutOfBoundsException
-    *         if {@code this.readableBytes} is less than {@code 4}
+    * @throws IndexOutOfBoundsException if {@code this.readableBytes} is less than {@code 4}
     */
-   int   readInt();
+   int readInt();
 
    /**
     * Gets an unsigned 32-bit integer at the current {@code readerIndex}
     * and increases the {@code readerIndex} by {@code 4} in this buffer.
     *
     * @return an unsigned 32-bit integer at the current {@code readerIndex}
-    * @throws IndexOutOfBoundsException
-    *         if {@code this.readableBytes} is less than {@code 4}
+    * @throws IndexOutOfBoundsException if {@code this.readableBytes} is less than {@code 4}
     */
-   long  readUnsignedInt();
+   long readUnsignedInt();
 
    /**
     * Gets a 64-bit integer at the current {@code readerIndex}
     * and increases the {@code readerIndex} by {@code 8} in this buffer.
     *
     * @return a 64-bit integer at the current {@code readerIndex}
-    * @throws IndexOutOfBoundsException
-    *         if {@code this.readableBytes} is less than {@code 8}
+    * @throws IndexOutOfBoundsException if {@code this.readableBytes} is less than {@code 8}
     */
-   long  readLong();
+   long readLong();
 
    /**
     * Gets a char at the current {@code readerIndex}
     * and increases the {@code readerIndex} by {@code 2} in this buffer.
     *
     * @return a char at the current {@code readerIndex}
-    * @throws IndexOutOfBoundsException
-    *         if {@code this.readableBytes} is less than {@code 2}
+    * @throws IndexOutOfBoundsException if {@code this.readableBytes} is less than {@code 2}
     */
    char readChar();
 
@@ -749,8 +703,7 @@ public interface ActiveMQBuffer
     * and increases the {@code readerIndex} by {@code 4} in this buffer.
     *
     * @return a float at the current {@code readerIndex}
-    * @throws IndexOutOfBoundsException
-    *         if {@code this.readableBytes} is less than {@code 4}
+    * @throws IndexOutOfBoundsException if {@code this.readableBytes} is less than {@code 4}
     */
    float readFloat();
 
@@ -759,8 +712,7 @@ public interface ActiveMQBuffer
     * and increases the {@code readerIndex} by {@code 8} in this buffer.
     *
     * @return a double at the current {@code readerIndex}
-    * @throws IndexOutOfBoundsException
-    *         if {@code this.readableBytes} is less than {@code 8}
+    * @throws IndexOutOfBoundsException if {@code this.readableBytes} is less than {@code 8}
     */
    double readDouble();
 
@@ -769,8 +721,7 @@ public interface ActiveMQBuffer
     * and increases the {@code readerIndex} by {@code 1} in this buffer.
     *
     * @return a boolean at the current {@code readerIndex}
-    * @throws IndexOutOfBoundsException
-    *         if {@code this.readableBytes} is less than {@code 1}
+    * @throws IndexOutOfBoundsException if {@code this.readableBytes} is less than {@code 1}
     */
    boolean readBoolean();
 
@@ -817,11 +768,8 @@ public interface ActiveMQBuffer
     * {@code 0} and {@code length} respectively.
     *
     * @param length the number of bytes to transfer
-
     * @return the newly created buffer which contains the transferred bytes
-    *
-    * @throws IndexOutOfBoundsException
-    *         if {@code length} is greater than {@code this.readableBytes}
+    * @throws IndexOutOfBoundsException if {@code length} is greater than {@code this.readableBytes}
     */
    ActiveMQBuffer readBytes(int length);
 
@@ -831,11 +779,8 @@ public interface ActiveMQBuffer
     * of the new slice (= {@code length}).
     *
     * @param length the size of the new slice
-    *
     * @return the newly created slice
-    *
-    * @throws IndexOutOfBoundsException
-    *         if {@code length} is greater than {@code this.readableBytes}
+    * @throws IndexOutOfBoundsException if {@code length} is greater than {@code this.readableBytes}
     */
    ActiveMQBuffer readSlice(int length);
 
@@ -850,9 +795,8 @@ public interface ActiveMQBuffer
     * does not.
     *
     * @param dst The destination buffer
-    * @throws IndexOutOfBoundsException
-    *         if {@code dst.writableBytes} is greater than
-    *            {@code this.readableBytes}
+    * @throws IndexOutOfBoundsException if {@code dst.writableBytes} is greater than
+    *                                   {@code this.readableBytes}
     */
    void readBytes(ActiveMQBuffer dst);
 
@@ -865,11 +809,10 @@ public interface ActiveMQBuffer
     * destination by the number of the transferred bytes (= {@code length})
     * while {@link #readBytes(ActiveMQBuffer, int, int)} does not.
     *
-    * @param dst The destination buffer
+    * @param dst    The destination buffer
     * @param length The number of bytes to transfer
-    * @throws IndexOutOfBoundsException
-    *         if {@code length} is greater than {@code this.readableBytes} or
-    *         if {@code length} is greater than {@code dst.writableBytes}
+    * @throws IndexOutOfBoundsException if {@code length} is greater than {@code this.readableBytes} or
+    *                                   if {@code length} is greater than {@code dst.writableBytes}
     */
    void readBytes(ActiveMQBuffer dst, int length);
 
@@ -880,13 +823,11 @@ public interface ActiveMQBuffer
     *
     * @param dstIndex The destination buffer index
     * @param length   the number of bytes to transfer
-    * @param dst The destination buffer
-    *
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code dstIndex} is less than {@code 0},
-    *         if {@code length} is greater than {@code this.readableBytes}, or
-    *         if {@code dstIndex + length} is greater than
-    *            {@code dst.capacity}
+    * @param dst      The destination buffer
+    * @throws IndexOutOfBoundsException if the specified {@code dstIndex} is less than {@code 0},
+    *                                   if {@code length} is greater than {@code this.readableBytes}, or
+    *                                   if {@code dstIndex + length} is greater than
+    *                                   {@code dst.capacity}
     */
    void readBytes(ActiveMQBuffer dst, int dstIndex, int length);
 
@@ -896,8 +837,7 @@ public interface ActiveMQBuffer
     * by the number of the transferred bytes (= {@code dst.length}).
     *
     * @param dst The destination buffer
-    * @throws IndexOutOfBoundsException
-    *         if {@code dst.length} is greater than {@code this.readableBytes}
+    * @throws IndexOutOfBoundsException if {@code dst.length} is greater than {@code this.readableBytes}
     */
    void readBytes(byte[] dst);
 
@@ -908,12 +848,10 @@ public interface ActiveMQBuffer
     *
     * @param dstIndex The destination bufferIndex
     * @param length   the number of bytes to transfer
-    * @param dst The destination buffer
-    *
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code dstIndex} is less than {@code 0},
-    *         if {@code length} is greater than {@code this.readableBytes}, or
-    *         if {@code dstIndex + length} is greater than {@code dst.length}
+    * @param dst      The destination buffer
+    * @throws IndexOutOfBoundsException if the specified {@code dstIndex} is less than {@code 0},
+    *                                   if {@code length} is greater than {@code this.readableBytes}, or
+    *                                   if {@code dstIndex + length} is greater than {@code dst.length}
     */
    void readBytes(byte[] dst, int dstIndex, int length);
 
@@ -924,9 +862,8 @@ public interface ActiveMQBuffer
     * number of the transferred bytes.
     *
     * @param dst The destination buffer
-    * @throws IndexOutOfBoundsException
-    *         if {@code dst.remaining()} is greater than
-    *            {@code this.readableBytes}
+    * @throws IndexOutOfBoundsException if {@code dst.remaining()} is greater than
+    *                                   {@code this.readableBytes}
     */
    void readBytes(ByteBuffer dst);
 
@@ -935,8 +872,7 @@ public interface ActiveMQBuffer
     * {@code length} in this buffer.
     *
     * @param length The number of bytes to skip
-    * @throws IndexOutOfBoundsException
-    *         if {@code length} is greater than {@code this.readableBytes}
+    * @throws IndexOutOfBoundsException if {@code length} is greater than {@code this.readableBytes}
     */
    void skipBytes(int length);
 
@@ -945,10 +881,9 @@ public interface ActiveMQBuffer
     * and increases the {@code writerIndex} by {@code 1} in this buffer.
     *
     * @param value The specified byte
-    * @throws IndexOutOfBoundsException
-    *         if {@code this.writableBytes} is less than {@code 1}
+    * @throws IndexOutOfBoundsException if {@code this.writableBytes} is less than {@code 1}
     */
-   void writeByte(byte  value);
+   void writeByte(byte value);
 
    /**
     * Sets the specified 16-bit short integer at the current
@@ -956,8 +891,7 @@ public interface ActiveMQBuffer
     * in this buffer.
     *
     * @param value The specified 16-bit short integer
-    * @throws IndexOutOfBoundsException
-    *         if {@code this.writableBytes} is less than {@code 2}
+    * @throws IndexOutOfBoundsException if {@code this.writableBytes} is less than {@code 2}
     */
    void writeShort(short value);
 
@@ -966,10 +900,9 @@ public interface ActiveMQBuffer
     * and increases the {@code writerIndex} by {@code 4} in this buffer.
     *
     * @param value The specified 32-bit integer
-    * @throws IndexOutOfBoundsException
-    *         if {@code this.writableBytes} is less than {@code 4}
+    * @throws IndexOutOfBoundsException if {@code this.writableBytes} is less than {@code 4}
     */
-   void writeInt(int   value);
+   void writeInt(int value);
 
    /**
     * Sets the specified 64-bit long integer at the current
@@ -977,18 +910,16 @@ public interface ActiveMQBuffer
     * in this buffer.
     *
     * @param value The specified 64-bit long integer
-    * @throws IndexOutOfBoundsException
-    *         if {@code this.writableBytes} is less than {@code 8}
+    * @throws IndexOutOfBoundsException if {@code this.writableBytes} is less than {@code 8}
     */
-   void writeLong(long  value);
+   void writeLong(long value);
 
    /**
     * Sets the specified char at the current {@code writerIndex}
     * and increases the {@code writerIndex} by {@code 2} in this buffer.
     *
     * @param chr The specified char
-    * @throws IndexOutOfBoundsException
-    *         if {@code this.writableBytes} is less than {@code 2}
+    * @throws IndexOutOfBoundsException if {@code this.writableBytes} is less than {@code 2}
     */
    void writeChar(char chr);
 
@@ -997,8 +928,7 @@ public interface ActiveMQBuffer
     * and increases the {@code writerIndex} by {@code 4} in this buffer.
     *
     * @param value The specified float
-    * @throws IndexOutOfBoundsException
-    *         if {@code this.writableBytes} is less than {@code 4}
+    * @throws IndexOutOfBoundsException if {@code this.writableBytes} is less than {@code 4}
     */
    void writeFloat(float value);
 
@@ -1007,13 +937,13 @@ public interface ActiveMQBuffer
     * and increases the {@code writerIndex} by {@code 8} in this buffer.
     *
     * @param value The specified double
-    * @throws IndexOutOfBoundsException
-    *         if {@code this.writableBytes} is less than {@code 8}
+    * @throws IndexOutOfBoundsException if {@code this.writableBytes} is less than {@code 8}
     */
    void writeDouble(double value);
 
    /**
     * Sets the specified boolean at the current {@code writerIndex}
+    *
     * @param val The specified boolean
     */
    void writeBoolean(boolean val);
@@ -1064,10 +994,9 @@ public interface ActiveMQBuffer
     * {@link #writeBytes(ActiveMQBuffer, int, int)} does not.
     *
     * @param length the number of bytes to transfer
-    * @param src The source buffer
-    * @throws IndexOutOfBoundsException
-    *         if {@code length} is greater than {@code this.writableBytes} or
-    *         if {@code length} is greater then {@code src.readableBytes}
+    * @param src    The source buffer
+    * @throws IndexOutOfBoundsException if {@code length} is greater than {@code this.writableBytes} or
+    *                                   if {@code length} is greater then {@code src.readableBytes}
     */
    void writeBytes(ActiveMQBuffer src, int length);
 
@@ -1078,13 +1007,11 @@ public interface ActiveMQBuffer
     *
     * @param srcIndex the first index of the source
     * @param length   the number of bytes to transfer
-    * @param src The source buffer
-    *
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code srcIndex} is less than {@code 0},
-    *         if {@code srcIndex + length} is greater than
-    *            {@code src.capacity}, or
-    *         if {@code length} is greater than {@code this.writableBytes}
+    * @param src      The source buffer
+    * @throws IndexOutOfBoundsException if the specified {@code srcIndex} is less than {@code 0},
+    *                                   if {@code srcIndex + length} is greater than
+    *                                   {@code src.capacity}, or
+    *                                   if {@code length} is greater than {@code this.writableBytes}
     */
    void writeBytes(ActiveMQBuffer src, int srcIndex, int length);
 
@@ -1094,8 +1021,7 @@ public interface ActiveMQBuffer
     * by the number of the transferred bytes (= {@code src.length}).
     *
     * @param src The source buffer
-    * @throws IndexOutOfBoundsException
-    *         if {@code src.length} is greater than {@code this.writableBytes}
+    * @throws IndexOutOfBoundsException if {@code src.length} is greater than {@code this.writableBytes}
     */
    void writeBytes(byte[] src);
 
@@ -1106,13 +1032,11 @@ public interface ActiveMQBuffer
     *
     * @param srcIndex the first index of the source
     * @param length   the number of bytes to transfer
-    * @param src The source buffer
-    *
-    * @throws IndexOutOfBoundsException
-    *         if the specified {@code srcIndex} is less than {@code 0},
-    *         if {@code srcIndex + length} is greater than
-    *            {@code src.length}, or
-    *         if {@code length} is greater than {@code this.writableBytes}
+    * @param src      The source buffer
+    * @throws IndexOutOfBoundsException if the specified {@code srcIndex} is less than {@code 0},
+    *                                   if {@code srcIndex + length} is greater than
+    *                                   {@code src.length}, or
+    *                                   if {@code length} is greater than {@code this.writableBytes}
     */
    void writeBytes(byte[] src, int srcIndex, int length);
 
@@ -1123,9 +1047,8 @@ public interface ActiveMQBuffer
     * number of the transferred bytes.
     *
     * @param src The source buffer
-    * @throws IndexOutOfBoundsException
-    *         if {@code src.remaining()} is greater than
-    *            {@code this.writableBytes}
+    * @throws IndexOutOfBoundsException if {@code src.remaining()} is greater than
+    *                                   {@code this.writableBytes}
     */
    void writeBytes(ByteBuffer src);
 
@@ -1146,7 +1069,7 @@ public interface ActiveMQBuffer
     * This method does not modify {@code readerIndex} or {@code writerIndex} of
     * this buffer.
     *
-    * @param index Index into the buffer
+    * @param index  Index into the buffer
     * @param length The number of bytes to copy
     * @return a copy of this buffer's readable bytes.
     */
@@ -1171,7 +1094,7 @@ public interface ActiveMQBuffer
     * This method does not modify {@code readerIndex} or {@code writerIndex} of
     * this buffer.
     *
-    * @param index Index into the buffer
+    * @param index  Index into the buffer
     * @param length The number of bytes
     * @return a slice of this buffer's sub-region.
     */
@@ -1208,7 +1131,7 @@ public interface ActiveMQBuffer
     * This method does not modify {@code readerIndex} or {@code writerIndex} of
     * this buffer.
     *
-    * @param index Index into the buffer
+    * @param index  Index into the buffer
     * @param length The number of bytes
     * @return A converted NIO Buffer
     */

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/bac96047/artemis-commons/src/main/java/org/apache/activemq/artemis/api/core/ActiveMQBuffers.java
----------------------------------------------------------------------
diff --git a/artemis-commons/src/main/java/org/apache/activemq/artemis/api/core/ActiveMQBuffers.java b/artemis-commons/src/main/java/org/apache/activemq/artemis/api/core/ActiveMQBuffers.java
index 34fee4d..22f0f9a 100644
--- a/artemis-commons/src/main/java/org/apache/activemq/artemis/api/core/ActiveMQBuffers.java
+++ b/artemis-commons/src/main/java/org/apache/activemq/artemis/api/core/ActiveMQBuffers.java
@@ -24,16 +24,15 @@ import org.apache.activemq.artemis.core.buffers.impl.ChannelBufferWrapper;
 /**
  * Factory class to create instances of {@link ActiveMQBuffer}.
  */
-public final class ActiveMQBuffers
-{
+public final class ActiveMQBuffers {
+
    /**
     * Creates a <em>self-expanding</em> ActiveMQBuffer with the given initial size
     *
     * @param size the initial size of the created ActiveMQBuffer
     * @return a self-expanding ActiveMQBuffer starting with the given size
     */
-   public static ActiveMQBuffer dynamicBuffer(final int size)
-   {
+   public static ActiveMQBuffer dynamicBuffer(final int size) {
       return new ChannelBufferWrapper(Unpooled.buffer(size));
    }
 
@@ -43,8 +42,7 @@ public final class ActiveMQBuffers
     * @param bytes the created buffer will be initially filled with this byte array
     * @return a self-expanding ActiveMQBuffer filled with the given byte array
     */
-   public static ActiveMQBuffer dynamicBuffer(final byte[] bytes)
-   {
+   public static ActiveMQBuffer dynamicBuffer(final byte[] bytes) {
       ActiveMQBuffer buff = dynamicBuffer(bytes.length);
 
       buff.writeBytes(bytes);
@@ -60,8 +58,7 @@ public final class ActiveMQBuffers
     * @param underlying the underlying NIO ByteBuffer
     * @return an ActiveMQBuffer wrapping the underlying NIO ByteBuffer
     */
-   public static ActiveMQBuffer wrappedBuffer(final ByteBuffer underlying)
-   {
+   public static ActiveMQBuffer wrappedBuffer(final ByteBuffer underlying) {
       ActiveMQBuffer buff = new ChannelBufferWrapper(Unpooled.wrappedBuffer(underlying));
 
       buff.clear();
@@ -75,8 +72,7 @@ public final class ActiveMQBuffers
     * @param underlying the underlying byte array
     * @return an ActiveMQBuffer wrapping the underlying byte array
     */
-   public static ActiveMQBuffer wrappedBuffer(final byte[] underlying)
-   {
+   public static ActiveMQBuffer wrappedBuffer(final byte[] underlying) {
       return new ChannelBufferWrapper(Unpooled.wrappedBuffer(underlying));
    }
 
@@ -86,13 +82,11 @@ public final class ActiveMQBuffers
     * @param size the size of the created ActiveMQBuffer
     * @return a fixed ActiveMQBuffer with the given size
     */
-   public static ActiveMQBuffer fixedBuffer(final int size)
-   {
+   public static ActiveMQBuffer fixedBuffer(final int size) {
       return new ChannelBufferWrapper(Unpooled.buffer(size, size));
    }
 
-   private ActiveMQBuffers()
-   {
+   private ActiveMQBuffers() {
       // Utility class
    }
 }


Mime
View raw message