| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
Calamity.Gateway.Types
Description
Types for shards
Documentation
type ShardC r = Members '[LogEff, AtomicState ShardState, Embed IO, Final IO, Async, MetricEff] r Source #
Constructors
| Discord ReceivedDiscordMessage | |
| Control ControlMessage |
data ReceivedDiscordMessage Source #
Constructors
| EvtDispatch Int !DispatchData | |
| HeartBeatReq | |
| Reconnect | |
| InvalidSession Bool | |
| Hello Int | |
| HeartBeatAck |
Instances
| Show ReceivedDiscordMessage Source # | |
Defined in Calamity.Gateway.Types Methods showsPrec :: Int -> ReceivedDiscordMessage -> ShowS # show :: ReceivedDiscordMessage -> String # showList :: [ReceivedDiscordMessage] -> ShowS # | |
| FromJSON ReceivedDiscordMessage Source # | |
Defined in Calamity.Gateway.Types Methods parseJSON :: Value -> Parser ReceivedDiscordMessage # parseJSONList :: Value -> Parser [ReceivedDiscordMessage] # | |
data SentDiscordMessage Source #
Constructors
| StatusUpdate StatusUpdateData | |
| Identify IdentifyData | |
| HeartBeat (Maybe Int) | |
| VoiceStatusUpdate VoiceState | |
| Resume ResumeData | |
| RequestGuildMembers RequestGuildMembersData |
Instances
| Show SentDiscordMessage Source # | |
Defined in Calamity.Gateway.Types Methods showsPrec :: Int -> SentDiscordMessage -> ShowS # show :: SentDiscordMessage -> String # showList :: [SentDiscordMessage] -> ShowS # | |
| ToJSON SentDiscordMessage Source # | |
Defined in Calamity.Gateway.Types Methods toJSON :: SentDiscordMessage -> Value # toEncoding :: SentDiscordMessage -> Encoding # toJSONList :: [SentDiscordMessage] -> Value # toEncodingList :: [SentDiscordMessage] -> Encoding # | |
data DispatchType Source #
Constructors
Instances
data IdentifyData Source #
Constructors
| IdentifyData | |
Fields
| |
Instances
| Show IdentifyData Source # | |
Defined in Calamity.Gateway.Types Methods showsPrec :: Int -> IdentifyData -> ShowS # show :: IdentifyData -> String # showList :: [IdentifyData] -> ShowS # | |
| ToJSON IdentifyData Source # | |
Defined in Calamity.Gateway.Types Methods toJSON :: IdentifyData -> Value # toEncoding :: IdentifyData -> Encoding # toJSONList :: [IdentifyData] -> Value # toEncodingList :: [IdentifyData] -> Encoding # | |
| CalamityToJSON' IdentifyData Source # | |
Defined in Calamity.Gateway.Types | |
data StatusUpdateData Source #
Constructors
| StatusUpdateData | |
Fields
| |
Instances
| Show StatusUpdateData Source # | |
Defined in Calamity.Gateway.Types Methods showsPrec :: Int -> StatusUpdateData -> ShowS # show :: StatusUpdateData -> String # showList :: [StatusUpdateData] -> ShowS # | |
| ToJSON StatusUpdateData Source # | |
Defined in Calamity.Gateway.Types Methods toJSON :: StatusUpdateData -> Value # toEncoding :: StatusUpdateData -> Encoding # toJSONList :: [StatusUpdateData] -> Value # toEncodingList :: [StatusUpdateData] -> Encoding # | |
| CalamityToJSON' StatusUpdateData Source # | |
Defined in Calamity.Gateway.Types | |
data ResumeData Source #
Instances
| Show ResumeData Source # | |
Defined in Calamity.Gateway.Types Methods showsPrec :: Int -> ResumeData -> ShowS # show :: ResumeData -> String # showList :: [ResumeData] -> ShowS # | |
| ToJSON ResumeData Source # | |
Defined in Calamity.Gateway.Types Methods toJSON :: ResumeData -> Value # toEncoding :: ResumeData -> Encoding # toJSONList :: [ResumeData] -> Value # toEncodingList :: [ResumeData] -> Encoding # | |
| CalamityToJSON' ResumeData Source # | |
Defined in Calamity.Gateway.Types | |
data RequestGuildMembersData Source #
Constructors
| RequestGuildMembersData | |
Instances
| Show RequestGuildMembersData Source # | |
Defined in Calamity.Gateway.Types Methods showsPrec :: Int -> RequestGuildMembersData -> ShowS # show :: RequestGuildMembersData -> String # showList :: [RequestGuildMembersData] -> ShowS # | |
| ToJSON RequestGuildMembersData Source # | |
Defined in Calamity.Gateway.Types Methods toJSON :: RequestGuildMembersData -> Value # toEncoding :: RequestGuildMembersData -> Encoding # toJSONList :: [RequestGuildMembersData] -> Value # | |
| CalamityToJSON' RequestGuildMembersData Source # | |
Defined in Calamity.Gateway.Types | |
data IdentifyProps Source #
Constructors
| IdentifyProps | |
Instances
| Show IdentifyProps Source # | |
Defined in Calamity.Gateway.Types Methods showsPrec :: Int -> IdentifyProps -> ShowS # show :: IdentifyProps -> String # showList :: [IdentifyProps] -> ShowS # | |
| ToJSON IdentifyProps Source # | |
Defined in Calamity.Gateway.Types Methods toJSON :: IdentifyProps -> Value # toEncoding :: IdentifyProps -> Encoding # toJSONList :: [IdentifyProps] -> Value # toEncodingList :: [IdentifyProps] -> Encoding # | |
| CalamityToJSON' IdentifyProps Source # | |
Defined in Calamity.Gateway.Types | |
data ControlMessage Source #
Constructors
| RestartShard | |
| ShutDownShard | |
| SendPresence StatusUpdateData |
Instances
| Show ControlMessage Source # | |
Defined in Calamity.Gateway.Types Methods showsPrec :: Int -> ControlMessage -> ShowS # show :: ControlMessage -> String # showList :: [ControlMessage] -> ShowS # | |
data ShardFlowControl Source #
Constructors
| ShardFlowRestart | |
| ShardFlowShutDown |
Instances
| Show ShardFlowControl Source # | |
Defined in Calamity.Gateway.Types Methods showsPrec :: Int -> ShardFlowControl -> ShowS # show :: ShardFlowControl -> String # showList :: [ShardFlowControl] -> ShowS # | |
Constructors
| Shard | |
Fields
| |
Instances
data ShardState Source #
Constructors
| ShardState | |