@@ -1051,8 +1051,9 @@ func (c *Conn) CloseHandler() func(code int, text string) error {
1051
1051
// if the close message is empty. The default close handler sends a close
1052
1052
// message back to the peer.
1053
1053
//
1054
- // The application must read the connection to process close messages as
1055
- // described in the section on Control Messages above.
1054
+ // The handler function is called from the NextReader, ReadMessage and message
1055
+ // reader Read methods. The application must read the connection to process
1056
+ // close messages as described in the section on Control Messages above.
1056
1057
//
1057
1058
// The connection read methods return a CloseError when a close message is
1058
1059
// received. Most applications should handle close messages as part of their
@@ -1079,8 +1080,9 @@ func (c *Conn) PingHandler() func(appData string) error {
1079
1080
// The appData argument to h is the PING message application data. The default
1080
1081
// ping handler sends a pong to the peer.
1081
1082
//
1082
- // The application must read the connection to process ping messages as
1083
- // described in the section on Control Messages above.
1083
+ // The handler function is called from the NextReader, ReadMessage and message
1084
+ // reader Read methods. The application must read the connection to process
1085
+ // ping messages as described in the section on Control Messages above.
1084
1086
func (c * Conn ) SetPingHandler (h func (appData string ) error ) {
1085
1087
if h == nil {
1086
1088
h = func (message string ) error {
@@ -1105,8 +1107,9 @@ func (c *Conn) PongHandler() func(appData string) error {
1105
1107
// The appData argument to h is the PONG message application data. The default
1106
1108
// pong handler does nothing.
1107
1109
//
1108
- // The application must read the connection to process ping messages as
1109
- // described in the section on Control Messages above.
1110
+ // The handler function is called from the NextReader, ReadMessage and message
1111
+ // reader Read methods. The application must read the connection to process
1112
+ // pong messages as described in the section on Control Messages above.
1110
1113
func (c * Conn ) SetPongHandler (h func (appData string ) error ) {
1111
1114
if h == nil {
1112
1115
h = func (string ) error { return nil }
0 commit comments