Copyright | (c) digitally induced GmbH 2020 |
---|---|
Safe Haskell | None |
IHP.WebSocket
Contents
Description
Documentation
class WSApp state where Source #
Minimal complete definition
Methods
initialState :: state Source #
run :: (?state :: IORef state, ?context :: ControllerContext, ?applicationContext :: ApplicationContext, ?connection :: Connection) => IO () Source #
onPing :: (?state :: IORef state, ?context :: ControllerContext, ?applicationContext :: ApplicationContext, ?connection :: Connection) => IO () Source #
onClose :: (?state :: IORef state, ?context :: ControllerContext, ?applicationContext :: ApplicationContext, ?connection :: Connection) => IO () Source #
startWSApp :: forall state. (WSApp state, ?applicationContext :: ApplicationContext, ?requestContext :: RequestContext) => Connection -> IO () Source #
receiveData :: (?connection :: Connection, WebSocketsData a) => IO a Source #
receiveDataMessage :: (?connection :: Connection) => IO DataMessage Source #
sendTextData :: (?connection :: Connection, WebSocketsData text) => text -> IO () Source #
Orphan instances
WebSocketsData UUID Source # | |
Methods fromDataMessage :: DataMessage -> UUID fromLazyByteString :: ByteString -> UUID toLazyByteString :: UUID -> ByteString |