@Target(value={METHOD,TYPE})
@Retention(value=RUNTIME)
@Documented
public @interface SendToUser
Message to the specified
destination(s) prepended with "/user/{username}" where the user name
is extracted from the headers of the input message being handled.
The annotation may also be placed at class-level in which case all methods in the class where the annotation applies will inherit it.
SendToMethodReturnValueHandler,
UserDestinationMessageHandler,
SimpMessageHeaderAccessor.getUser()| Modifier and Type | Optional Element and Description |
|---|---|
boolean |
broadcast
Whether messages should be sent to all sessions associated with the user
or only to the session of the input message being handled.
|
java.lang.String[] |
destinations
One or more destinations to send a message to.
|
java.lang.String[] |
value
Alias for
destinations(). |
@AliasFor(value="destinations") public abstract java.lang.String[] value
destinations().destinations()@AliasFor(value="value") public abstract java.lang.String[] destinations
If left unspecified, a default destination is selected based on the destination of the input message being handled.
value(),
SendToMethodReturnValueHandler