public class StompConnection extends Object
| Modifier and Type | Field and Description |
|---|---|
static long |
RECEIVE_TIMEOUT |
| Constructor and Description |
|---|
StompConnection() |
| Modifier and Type | Method and Description |
|---|---|
void |
abort(String transaction) |
void |
ack(StompFrame frame) |
void |
ack(StompFrame frame,
String transaction) |
void |
ack(String messageId) |
void |
ack(String messageId,
String transaction) |
protected String |
appendHeaders(HashMap<String,Object> headers) |
void |
begin(String transaction) |
void |
close() |
void |
commit(String transaction) |
void |
connect(HashMap<String,String> headers) |
void |
connect(String username,
String password) |
void |
connect(String username,
String password,
String client) |
void |
disconnect() |
void |
disconnect(String receiptId) |
Socket |
getStompSocket() |
String |
getVersion() |
void |
keepAlive() |
void |
open(Socket socket) |
void |
open(String host,
int port) |
StompFrame |
receive() |
StompFrame |
receive(long timeOut) |
String |
receiveFrame() |
String |
receiveFrame(long timeOut) |
void |
send(String destination,
String message) |
void |
send(String destination,
String message,
String transaction,
HashMap<String,String> headers) |
void |
sendFrame(String data) |
void |
sendFrame(String frame,
byte[] data) |
void |
setStompSocket(Socket stompSocket) |
void |
setVersion(String version) |
void |
subscribe(String destination) |
void |
subscribe(String destination,
String ack) |
void |
subscribe(String destination,
String ack,
HashMap<String,String> headers) |
void |
unsubscribe(String destination) |
void |
unsubscribe(String destination,
HashMap<String,String> headers) |
public static final long RECEIVE_TIMEOUT
public StompConnection()
public void open(String host, int port) throws IOException, UnknownHostException
IOExceptionUnknownHostExceptionpublic void close() throws IOException
IOExceptionpublic StompFrame receive() throws Exception
Exceptionpublic StompFrame receive(long timeOut) throws Exception
Exceptionpublic String receiveFrame() throws Exception
Exceptionpublic String receiveFrame(long timeOut) throws Exception
Exceptionpublic Socket getStompSocket()
public void setStompSocket(Socket stompSocket)
public void connect(String username, String password, String client) throws Exception
Exceptionpublic void disconnect() throws Exception
Exceptionpublic void disconnect(String receiptId) throws Exception
Exceptionpublic void send(String destination, String message, String transaction, HashMap<String,String> headers) throws Exception
Exceptionpublic void subscribe(String destination, String ack, HashMap<String,String> headers) throws Exception
Exceptionpublic void unsubscribe(String destination) throws Exception
Exceptionpublic void unsubscribe(String destination, HashMap<String,String> headers) throws Exception
Exceptionpublic void ack(StompFrame frame) throws Exception
Exceptionpublic void ack(StompFrame frame, String transaction) throws Exception
Exceptionprotected String appendHeaders(HashMap<String,Object> headers)
public String getVersion()
public void setVersion(String version)
Copyright © 2005–2016 FuseSource, Corp.. All rights reserved.