Package org.jboss.as.server.services.net

Examples of org.jboss.as.server.services.net.SocketBindingService


                    final String mcastAddr = resolvedOp.get(MULTICAST_ADDRESS).isDefined() ? resolvedOp.get(MULTICAST_ADDRESS).asString() : null;
                    final int mcastPort = resolvedOp.get(MULTICAST_PORT).isDefined() ? resolvedOp.get(MULTICAST_PORT).asInt() : 0;
                    try {
                        InetAddress mcastInet = mcastAddr == null ? null : InetAddress.getByName(mcastAddr);

                        final SocketBindingService service = new SocketBindingService(name, port, fixedPort, mcastInet, mcastPort);
                        final ServiceBuilder<SocketBinding> builder = serviceTarget.addService(SocketBinding.JBOSS_BINDING_NAME.append(name), service);
                        if (intf != null) {
                            builder.addDependency(NetworkInterfaceService.JBOSS_NETWORK_INTERFACE.append(intf), NetworkInterfaceBinding.class, service.getInterfaceBinding());
                        }
                        builder.addDependency(SocketBindingManager.SOCKET_BINDING_MANAGER, SocketBindingManager.class, service.getSocketBindings())
                                .setInitialMode(Mode.ON_DEMAND)
                                .install();

                        resultHandler.handleResultComplete();
                    } catch (UnknownHostException e) {
View Full Code Here


                    final String mcastAddr = resolvedOp.get(MULTICAST_ADDRESS).isDefined() ? resolvedOp.get(MULTICAST_ADDRESS).asString() : null;
                    final int mcastPort = resolvedOp.get(MULTICAST_PORT).isDefined() ? resolvedOp.get(MULTICAST_PORT).asInt() : 0;
                    try {
                        InetAddress mcastInet = mcastAddr == null ? null : InetAddress.getByName(mcastAddr);

                        final SocketBindingService service = new SocketBindingService(name, port, fixedPort, mcastInet, mcastPort);
                        final ServiceBuilder<SocketBinding> builder = serviceTarget.addService(SocketBinding.JBOSS_BINDING_NAME.append(name), service);
                        if (intf != null) {
                            builder.addDependency(NetworkInterfaceService.JBOSS_NETWORK_INTERFACE.append(intf), NetworkInterfaceBinding.class, service.getInterfaceBinding());
                        }
                        builder.addDependency(SocketBindingManager.SOCKET_BINDING_MANAGER, SocketBindingManager.class, service.getSocketBindings())
                                .setInitialMode(Mode.ON_DEMAND)
                                .install();

                        resultHandler.handleResultComplete();
                    } catch (UnknownHostException e) {
View Full Code Here

TOP

Related Classes of org.jboss.as.server.services.net.SocketBindingService

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.