@StampyLibrary(libraryName="stampy-client-server") public class StampyHandlerHelper extends java.lang.Object
| Constructor and Description |
|---|
StampyHandlerHelper() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
errorHandle(java.lang.Exception e,
HostPort hostPort)
Error handle.
|
protected void |
errorHandle(StampyMessage<?> message,
java.lang.Exception e,
HostPort hostPort)
Error handle.
|
AbstractStampyMessageGateway |
getGateway() |
StampyHeartbeatContainer |
getHeartbeatContainer() |
StompMessageParser |
getParser() |
UnparseableMessageHandler |
getUnparseableMessageHandler() |
void |
handleUnexpectedError(HostPort hostPort,
java.lang.String msg,
StampyMessage<?> sm,
java.lang.Exception e)
Handle unexpected error.
|
void |
handleUnparseableMessage(HostPort hostPort,
java.lang.String msg,
UnparseableException e)
Handle unparseable message.
|
boolean |
isHeartbeat(java.lang.String msg)
Checks if the message is a heartbeat.
|
boolean |
isValidObject(java.lang.Object message)
Checks if is valid object.
|
void |
resetHeartbeat(HostPort hostPort)
Reset heartbeat.
|
void |
setGateway(AbstractStampyMessageGateway gateway) |
void |
setHeartbeatContainer(StampyHeartbeatContainer heartbeatContainer) |
void |
setParser(StompMessageParser parser) |
void |
setUnparseableMessageHandler(UnparseableMessageHandler unparseableMessageHandler) |
public void handleUnexpectedError(HostPort hostPort, java.lang.String msg, StampyMessage<?> sm, java.lang.Exception e)
hostPort - the host portmsg - the msgsm - the sme - the epublic void handleUnparseableMessage(HostPort hostPort, java.lang.String msg, UnparseableException e)
hostPort - the host portmsg - the msge - the eprotected void errorHandle(StampyMessage<?> message, java.lang.Exception e, HostPort hostPort) throws java.lang.Exception
message - the messagee - the ehostPort - the host portjava.lang.Exception - the exceptionprotected void errorHandle(java.lang.Exception e,
HostPort hostPort)
throws java.lang.Exception
e - the ehostPort - the host portjava.lang.Exception - the exceptionpublic boolean isHeartbeat(java.lang.String msg)
msg - the msgpublic boolean isValidObject(java.lang.Object message)
message - the messagepublic void resetHeartbeat(HostPort hostPort)
hostPort - the host portpublic StompMessageParser getParser()
public void setParser(StompMessageParser parser)
public StampyHeartbeatContainer getHeartbeatContainer()
public void setHeartbeatContainer(StampyHeartbeatContainer heartbeatContainer)
public AbstractStampyMessageGateway getGateway()
public void setGateway(AbstractStampyMessageGateway gateway)
public UnparseableMessageHandler getUnparseableMessageHandler()
public void setUnparseableMessageHandler(UnparseableMessageHandler unparseableMessageHandler)