subscribeBytes method

void subscribeBytes (String id, String destination, void onMessage(Map<String, String> headers, List<int> message), { Ack ack: AUTO, String receipt, Matcher matcher: exact, Map extraHeaders })

Subscribes for listening a given destination; assuming the message

  • are an array of bytes (aka., octets).
  • stomp.subscribe("/foo", (List<int> message) {
    
  •   //handle message (an array of octets)
    
  • });
    
    • id - specifies the id of the subscription. It must be unique
  • for each StompClient (until unsubscribe is called).
    • destination - specifies the destination to subscribe.
    • matcher - matches destination with the message's destination.
  • If omitted, exact is assumed.
    • extraHeaders - additional headers to be sent while subscribing.
  • If you'd like to specify a regular expression in destination,
  • you can use regExp. For GLOB pattern, use glob.
  • If you'd like to ignore the destination, use all.

Implementation

void subscribeBytes(String id, String destination,
    void onMessage(Map<String, String> headers, List<int> message),
    {Ack ack: AUTO,
    String receipt,
    Matcher matcher: exact,
    Map extraHeaders});