@Target(value={TYPE,METHOD}) @Retention(value=RUNTIME) @Documented public @interface WampSubscribeListener
SubscribeMessage and the topicURI matches one of the listed values of
the annotation.
If no topicURI is provided the method is accessible by the topicURI
'beanName.methodName'
In the following example the method can be called by sending a
SubscribeMessage with the topicURI 'myService.doSomething'
@Service
public class MyService {
@WampSubscribeListener
public void doSomething(SubscribeMessage message) {
}
}
If the attribute replyTo has a value the return value of the method (if any)
will be wrapped into an EventMessage and sent to the listed
topicURI(s). Additionally if the excludeSender attribute is true the sender
of the SubscribeMessage does not receive an EventMessage.| Modifier and Type | Optional Element and Description |
|---|---|
boolean |
excludeSender
Exclude the sender of the
SubscribeMessage from the replyTo
receivers. |
String[] |
replyTo
Send the return value with an
EventMessage to the listed
TopicURI(s) |
String[] |
value
TopicURI(s) for the subscription.
|
public abstract String[] value
public abstract String[] replyTo
EventMessage to the listed
TopicURI(s)public abstract boolean excludeSender
SubscribeMessage from the replyTo
receivers. This attribut will be ignored if no EventMessage is
created.Copyright © 2014. All Rights Reserved.