Safe Haskell | Safe-Inferred |
---|---|
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
FromJSON ReceivedDiscordMessage Source # | |
Defined in Calamity.Gateway.Types Methods parseJSON :: Value -> Parser ReceivedDiscordMessage # parseJSONList :: Value -> Parser [ReceivedDiscordMessage] # | |
Show ReceivedDiscordMessage Source # | |
Defined in Calamity.Gateway.Types Methods showsPrec :: Int -> ReceivedDiscordMessage -> ShowS # show :: ReceivedDiscordMessage -> String # showList :: [ReceivedDiscordMessage] -> ShowS # |
data SentDiscordMessage Source #
Constructors
StatusUpdate StatusUpdateData | |
Identify IdentifyData | |
HeartBeat (Maybe Int) | |
VoiceStatusUpdate VoiceState | |
Resume ResumeData | |
RequestGuildMembers RequestGuildMembersData |
Instances
ToJSON SentDiscordMessage Source # | |
Defined in Calamity.Gateway.Types Methods toJSON :: SentDiscordMessage -> Value # toEncoding :: SentDiscordMessage -> Encoding # toJSONList :: [SentDiscordMessage] -> Value # toEncodingList :: [SentDiscordMessage] -> Encoding # | |
Show SentDiscordMessage Source # | |
Defined in Calamity.Gateway.Types Methods showsPrec :: Int -> SentDiscordMessage -> ShowS # show :: SentDiscordMessage -> String # showList :: [SentDiscordMessage] -> ShowS # |
data DispatchType Source #
Constructors
Instances
data IdentifyData Source #
Constructors
IdentifyData | |
Fields
|
Instances
ToJSON IdentifyData Source # | |
Defined in Calamity.Gateway.Types Methods toJSON :: IdentifyData -> Value # toEncoding :: IdentifyData -> Encoding # toJSONList :: [IdentifyData] -> Value # toEncodingList :: [IdentifyData] -> Encoding # | |
Show IdentifyData Source # | |
Defined in Calamity.Gateway.Types Methods showsPrec :: Int -> IdentifyData -> ShowS # show :: IdentifyData -> String # showList :: [IdentifyData] -> ShowS # | |
CalamityToJSON' IdentifyData Source # | |
Defined in Calamity.Gateway.Types |
data StatusUpdateData Source #
Constructors
StatusUpdateData | |
Fields
|
Instances
ToJSON StatusUpdateData Source # | |
Defined in Calamity.Gateway.Types Methods toJSON :: StatusUpdateData -> Value # toEncoding :: StatusUpdateData -> Encoding # toJSONList :: [StatusUpdateData] -> Value # toEncodingList :: [StatusUpdateData] -> Encoding # | |
Show StatusUpdateData Source # | |
Defined in Calamity.Gateway.Types Methods showsPrec :: Int -> StatusUpdateData -> ShowS # show :: StatusUpdateData -> String # showList :: [StatusUpdateData] -> ShowS # | |
CalamityToJSON' StatusUpdateData Source # | |
Defined in Calamity.Gateway.Types |
data ResumeData Source #
Instances
ToJSON ResumeData Source # | |
Defined in Calamity.Gateway.Types Methods toJSON :: ResumeData -> Value # toEncoding :: ResumeData -> Encoding # toJSONList :: [ResumeData] -> Value # toEncodingList :: [ResumeData] -> Encoding # | |
Show ResumeData Source # | |
Defined in Calamity.Gateway.Types Methods showsPrec :: Int -> ResumeData -> ShowS # show :: ResumeData -> String # showList :: [ResumeData] -> ShowS # | |
CalamityToJSON' ResumeData Source # | |
Defined in Calamity.Gateway.Types |
data RequestGuildMembersData Source #
Constructors
RequestGuildMembersData | |
Instances
ToJSON RequestGuildMembersData Source # | |
Defined in Calamity.Gateway.Types Methods toJSON :: RequestGuildMembersData -> Value # toEncoding :: RequestGuildMembersData -> Encoding # toJSONList :: [RequestGuildMembersData] -> Value # | |
Show RequestGuildMembersData Source # | |
Defined in Calamity.Gateway.Types Methods showsPrec :: Int -> RequestGuildMembersData -> ShowS # show :: RequestGuildMembersData -> String # showList :: [RequestGuildMembersData] -> ShowS # | |
CalamityToJSON' RequestGuildMembersData Source # | |
Defined in Calamity.Gateway.Types |
data IdentifyProps Source #
Constructors
IdentifyProps | |
Instances
ToJSON IdentifyProps Source # | |
Defined in Calamity.Gateway.Types Methods toJSON :: IdentifyProps -> Value # toEncoding :: IdentifyProps -> Encoding # toJSONList :: [IdentifyProps] -> Value # toEncodingList :: [IdentifyProps] -> Encoding # | |
Show IdentifyProps Source # | |
Defined in Calamity.Gateway.Types Methods showsPrec :: Int -> IdentifyProps -> ShowS # show :: IdentifyProps -> String # showList :: [IdentifyProps] -> ShowS # | |
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 | |