public class StompFrame extends Object
Modifier and Type | Class and Description |
---|---|
class |
StompFrame.Header |
Modifier and Type | Field and Description |
---|---|
protected HornetQBuffer |
buffer |
protected byte[] |
bytesBody |
protected String |
command |
protected Map<String,String> |
headers |
protected int |
size |
Constructor and Description |
---|
StompFrame(String command) |
StompFrame(String command,
boolean disconnect) |
StompFrame(String command,
Map<String,String> headers,
byte[] content) |
Modifier and Type | Method and Description |
---|---|
void |
addHeader(String key,
String val) |
String |
escape(String str) |
String |
getBody() |
byte[] |
getBodyAsBytes() |
String |
getCommand() |
int |
getEncodedSize() |
String |
getHeader(String key) |
Map<String,String> |
getHeadersMap() |
boolean |
hasHeader(String key) |
boolean |
isPing() |
boolean |
needsDisconnect() |
void |
setBody(String body) |
void |
setByteBody(byte[] content) |
void |
setNeedsDisconnect(boolean b) |
void |
setPing(boolean ping) |
HornetQBuffer |
toHornetQBuffer() |
String |
toString() |
protected final String command
protected byte[] bytesBody
protected HornetQBuffer buffer
protected int size
public StompFrame(String command)
public StompFrame(String command, boolean disconnect)
public String getCommand()
public boolean isPing()
public void setPing(boolean ping)
public HornetQBuffer toHornetQBuffer() throws Exception
Exception
public void setBody(String body) throws UnsupportedEncodingException
UnsupportedEncodingException
public boolean hasHeader(String key)
public String getBody() throws UnsupportedEncodingException
UnsupportedEncodingException
public byte[] getBodyAsBytes() throws UnsupportedEncodingException
UnsupportedEncodingException
public boolean needsDisconnect()
public void setByteBody(byte[] content)
public void setNeedsDisconnect(boolean b)
Copyright © 2013 JBoss by Red Hat. All Rights Reserved.