Errai 3.0.1-SNAPSHOT

org.jboss.errai.ioc.support.bus.client
Class ErraiMessageSender<T>

java.lang.Object
  extended by org.jboss.errai.ioc.support.bus.client.ErraiMessageSender<T>
All Implemented Interfaces:
Sender<T>

public final class ErraiMessageSender<T>
extends Object
implements Sender<T>


Method Summary
static
<U> ErraiMessageSender<U>
of(String toSubject, String replyTo, MessageBus messageBus)
           
 void send(T value)
          Sends the message to the subject specified by ToSubject.
 void send(T value, ErrorCallback errorCallback)
          Sends the message to the subject specified by ToSubject.
 void send(T value, MessageCallback replyTo)
          Sends the message to the subject specified by ToSubject.
 void send(T value, MessageCallback replyTo, ErrorCallback errorCallback)
          Sends the message to the subject specified by ToSubject.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

of

public static <U> ErraiMessageSender<U> of(String toSubject,
                                           String replyTo,
                                           MessageBus messageBus)

send

public void send(T value)
Description copied from interface: Sender
Sends the message to the subject specified by ToSubject.

Specified by:
send in interface Sender<T>
Parameters:
value - the payload of the message stored in MessageParts.Value

send

public void send(T value,
                 ErrorCallback errorCallback)
Description copied from interface: Sender
Sends the message to the subject specified by ToSubject.

Specified by:
send in interface Sender<T>
Parameters:
value - the payload of the message stored in MessageParts.Value
errorCallback - a callback to be registered to handle errors when sending the message

send

public void send(T value,
                 MessageCallback replyTo)
Description copied from interface: Sender
Sends the message to the subject specified by ToSubject.

Specified by:
send in interface Sender<T>
Parameters:
value - the payload of the message stored in MessageParts.Value
replyTo - a callback to be registered to handle a reply from the remote service

send

public void send(T value,
                 MessageCallback replyTo,
                 ErrorCallback errorCallback)
Description copied from interface: Sender
Sends the message to the subject specified by ToSubject.

Specified by:
send in interface Sender<T>
Parameters:
value - the payload of the message stored in MessageParts.Value
replyTo - a callback to be registered to handle a reply from the remote service
errorCallback - a callback to be registered to handle errors when sending the message

Errai 3.0.1-SNAPSHOT

Copyright © 2013-2014 JBoss, a division of Red Hat. All Rights Reserved.