public class WSNotificationHandler extends NotificationHandler implements javax.websocket.MessageHandler
_error_delay, _hub, _notifRetryCount, _notifyPos, NOTIFY_NETPKT_CHILD, NOTIFY_NETPKT_DEVLOGYDX, NOTIFY_NETPKT_FLUSHV2YDX, NOTIFY_NETPKT_FUNCNAME, NOTIFY_NETPKT_FUNCNAMEYDX, NOTIFY_NETPKT_FUNCV2YDX, NOTIFY_NETPKT_FUNCVAL, NOTIFY_NETPKT_FUNCVALYDX, NOTIFY_NETPKT_NAME, NOTIFY_NETPKT_NOT_SYNC, NOTIFY_NETPKT_TIMEAVGYDX, NOTIFY_NETPKT_TIMEV2YDX, NOTIFY_NETPKT_TIMEVALYDX
Modifier and Type | Method and Description |
---|---|
boolean |
hasRwAccess() |
byte[] |
hubRequestSync(String req_first_line,
byte[] req_head_and_body,
int mstimeout) |
boolean |
isConnected() |
void |
onClose(javax.websocket.Session session,
javax.websocket.CloseReason closeReason) |
void |
onMessage(ByteBuffer raw_data,
javax.websocket.Session session) |
void |
onOpen(javax.websocket.Session session) |
void |
run() |
decodeNetFuncValV2, handleNetNotification
public byte[] hubRequestSync(String req_first_line, byte[] req_head_and_body, int mstimeout) throws YAPI_Exception, InterruptedException
req_first_line
- first line of request without space, HTTP1.1 or \r\nreq_head_and_body
- http headers with double \r\n followed by potential bodymstimeout
- number of milisecond allowed to the request to finishYAPI_Exception
InterruptedException
public boolean isConnected()
isConnected
in class NotificationHandler
public boolean hasRwAccess()
hasRwAccess
in class NotificationHandler
public void onOpen(javax.websocket.Session session)
public void onMessage(ByteBuffer raw_data, javax.websocket.Session session)
public void onClose(javax.websocket.Session session, javax.websocket.CloseReason closeReason)
Copyright © 2016. All rights reserved.