When a control callback is registered, it will be invoked for all pings, pongs, and close frames received through either synchronous read functions or asynchronous read functions. The type of frame and payload text are passed as parameters to the control callback. If the frame is a close frame, the close reason may be obtained by calling [link beast.ref.boost__beast__websocket__stream.reason `reason`].
When a control callback is registered, it will be invoked for all pings, pongs, and close frames received through either synchronous read functions or asynchronous read functions. The type of frame and payload text are passed as parameters to the control callback. If the frame is a close frame, the close reason may be obtained by calling [link beast.ref.boost__beast__websocket__stream.reason `reason`].