Bug 8153: Enforce check-style rules for netconf - netconf-ssh
[netconf.git] / netconf / netconf-ssh / src / main / java / org / opendaylight / netconf / ssh / NetconfNorthboundSshServer.java
index fca99e0b3c0e1f906abe237ecd1b87080d6c6e13..300e19f594368cd7d224fe7da4aa23dde88a81e0 100644 (file)
@@ -44,7 +44,8 @@ public class NetconfNorthboundSshServer {
         sshProxyServer = new SshProxyServer(Executors.newScheduledThreadPool(1), workerGroup, eventExecutor);
 
         final InetSocketAddress inetAddress = getInetAddress(bindingAddress, portNumber);
-        final SshProxyServerConfigurationBuilder sshProxyServerConfigurationBuilder = new SshProxyServerConfigurationBuilder();
+        final SshProxyServerConfigurationBuilder sshProxyServerConfigurationBuilder =
+                new SshProxyServerConfigurationBuilder();
         sshProxyServerConfigurationBuilder.setBindingAddress(inetAddress);
         sshProxyServerConfigurationBuilder.setLocalAddress(localAddress);
         sshProxyServerConfigurationBuilder.setAuthenticator(authProvider);
@@ -68,8 +69,9 @@ public class NetconfNorthboundSshServer {
 
     private InetSocketAddress getInetAddress(final String bindingAddress, final String portNumber) {
         try {
-            IpAddress ipAddress= IpAddressBuilder.getDefaultInstance(bindingAddress);
-            final InetAddress inetAd = InetAddress.getByName(ipAddress.getIpv4Address() == null ? ipAddress.getIpv6Address().getValue() : ipAddress.getIpv4Address().getValue());
+            IpAddress ipAddress = IpAddressBuilder.getDefaultInstance(bindingAddress);
+            final InetAddress inetAd = InetAddress.getByName(ipAddress.getIpv4Address() == null
+                    ? ipAddress.getIpv6Address().getValue() : ipAddress.getIpv4Address().getValue());
             return new InetSocketAddress(inetAd, Integer.valueOf(portNumber));
         } catch (final UnknownHostException e) {
             throw new IllegalArgumentException("Unable to bind netconf endpoint to address " + bindingAddress, e);