public Object callAndWait( byte channel, short objId, short procId, Object... args ) {
        
        RpcCallMessage msg = new RpcCallMessage(sequenceNumber.getAndIncrement(), 
                                                channel, objId, procId, args);
        
        // Need to register an object so we can wait for the response.
        // ...before we send it.  Just in case.
        ResponseHolder holder = new ResponseHolder(msg); 
        responses.put(msg.getMessageId(), holder);        
 
        if( log.isLoggable(Level.FINEST) ) {
            log.log(Level.FINEST, "Sending:{0}  on channel:{1}", new Object[]{msg, channel});
        }
        
        // Prevent non-async messages from being sent as UDP
        // because there is a high probability that this would block
        // forever waiting for a response.  For async calls it's ok
        // so it doesn't do the check.
        if( channel >= 0 ) {        
            connection.send(channel, msg);
        } else {
            connection.send(msg);
        }
                
        return holder.getResponse();
    }
Performs a remote procedure call with the specified arguments and waits
 for the response.  Both the outbound message and inbound response will
 be sent on the specified channel.
jme3-networking/src/main/java/com/jme3/network/service/rpc/RpcConnection.java