Package org.gradle.messaging.remote.internal.protocol

Examples of org.gradle.messaging.remote.internal.protocol.ChannelAvailable


    }

    private class DiscoveryMessageDispatch implements Dispatch<DiscoveryMessage> {
        public void dispatch(DiscoveryMessage message) {
            if (message instanceof ChannelAvailable) {
                ChannelAvailable available = (ChannelAvailable) message;
                Address serviceAddress = available.getAddress();
                lock.lock();
                try {
                    if (!channels.contains(available.getChannel())) {
                        return;
                    }
                    if (connections.contains(serviceAddress)) {
                        return;
                    }
View Full Code Here


    public <T> void addIncoming(Class<T> type, T handler) {
        String channelKey = type.getName();
        lock.lock();
        try {
            if (channels.add(channelKey)) {
                protocolStack.getTop().dispatch(new ChannelAvailable(messageOriginator, group, channelKey, address));
            }
        } finally {
            lock.unlock();
        }
        hub.addIncoming(channelKey, new TypeCastDispatch<MethodInvocation, Object>(MethodInvocation.class, new ReflectionDispatch(handler)));
View Full Code Here

TOP

Related Classes of org.gradle.messaging.remote.internal.protocol.ChannelAvailable

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.