@@ -25,7 +25,7 @@ public interface WebSocketListener {
25
25
void onOpen (WebSocket websocket );
26
26
27
27
/**
28
- * Invoked when the {@link WebSocket} is close .
28
+ * Invoked when the {@link WebSocket} is closed .
29
29
*
30
30
* @see "http://tools.ietf.org/html/rfc6455#section-5.5.1"
31
31
*
@@ -36,14 +36,14 @@ public interface WebSocketListener {
36
36
void onClose (WebSocket websocket , int code , String reason );
37
37
38
38
/**
39
- * Invoked when the {@link WebSocket} is open .
39
+ * Invoked when the {@link WebSocket} crashes .
40
40
*
41
41
* @param t a {@link Throwable}
42
42
*/
43
43
void onError (Throwable t );
44
44
45
45
/**
46
- * Invoked when bytes are available .
46
+ * Invoked when a binary frame is received .
47
47
*
48
48
* @param payload a byte array
49
49
* @param finalFragment true if this frame is the final fragment
@@ -53,7 +53,7 @@ default void onBinaryFrame(byte[] payload, boolean finalFragment, int rsv) {
53
53
};
54
54
55
55
/**
56
- * Invoked when WebSocket text message are received.
56
+ * Invoked when a text frame is received.
57
57
*
58
58
* @param payload a UTF-8 {@link String} message
59
59
* @param finalFragment true if this frame is the final fragment
@@ -63,15 +63,15 @@ default void onTextFrame(String payload, boolean finalFragment, int rsv) {
63
63
};
64
64
65
65
/**
66
- * Invoked when a ping message is received
66
+ * Invoked when a ping frame is received
67
67
*
68
68
* @param payload a byte array
69
69
*/
70
70
default void onPingFrame (byte [] payload ) {
71
71
};
72
72
73
73
/**
74
- * Invoked when a pong message is received
74
+ * Invoked when a pong frame is received
75
75
*
76
76
* @param payload a byte array
77
77
*/
0 commit comments