úÎĆiŸ“R      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQ None$"Quote types for string formatting..Backtick on each side of the formatted string. }Double quote on each side of the formatted string. The parameter sets whether to use Unicode (otherwise use ASCII fallback). }Single quote on each side of the formatted string. The parameter sets whether to use Unicode (otherwise use ASCII fallback). HA bot session action which reacts to a single event which came from an  .Type parameters:e - custom bot environment types - custom bot state typea - event type An RŽ action, possibly running forever, which produces events for the bot to process. These event sources are run by the bot in dedicated threads.Type parameters:e - custom bot environment types - custom bot state typea - event type Bot behavior definition.2Handle a channel member list received. Parameters:  Channel nameChannel privacyVList of channel members: their privilege level in the channel and their nicknamesSÖThe server sent a list of nicknames present in a channel. Parameters: Channel privacy mode, channel name, list of users. Each list item is a pair of a user privilege level in the channel, and the user's nickname.TTUnrecognized or unimplemented event. The parameter contains (possibly empty) input.UChannel, nickname, topicV‘A private message sent specifically to the bot, from a user with the given nickname (1st parameter) and with the given content (2nd parameter).WȘA bot command, which is a message with a special prefix, was sent to a channel. Parameters: Channel, sender nickname, prefix character, command name, command arguments.XÿBMessage (3rd parameter) referring to the bot sent by nick (2nd parameter) in a channel (1st parameter). The message begins with the bot's nick, followed by a colon or a comma. That part is however removed from the 3rd parameter. For example, if the message was "funbot, hello!" then the 3rd parameter will be "hello!".YLike Zź, but this is a notice. The bot shouldn't send a response (but it can modify its state etc.). First parameter: Just channel, or Nothing. The latter means a private message.ZșMessage (3rd parameter) sent in a channel (1st parameter) by a user with the given nickname (2nd parameter). The last parameter says whether the bot's nick is mentioned in the message.[ User, reason.\BA user (2nd parameter) left a channel (1st parameter), 3rd=reason.]8A user (2nd parameter) joined a channel (1st parameter).^jUsers (2nd parameter) have been kicked from a channel (1st parameter) for a given reason (3rd parameter)._mA ping was sent to the bot. The parameters contain the arguments passed, which should be passed in the Pong.…Bot monad. It provides read-only bot environment (e.g. the configuration), read-writable bot state (for use by bot commands) and IO.ÿThe bot recognizes commands by picking IRC channel messages which begin with a special character, the command prefix. It's possible to have several prefixes, maybe give each its own role or meaning. A command set is a set of commands which share a prefix.&A command can be in more than one set.Common prefixes are !, \@, `, :.QA bot command, triggered by a message sent to an IRC channel the bot has joined.The type parameter eG is the type of environment, i.e. real-only state. The type parameter sÉ is the type of the writable state the bot holds. For example, maybe you want your bot to keep a list of to-do items and manage it using bot commands. The bot state is where you store the to-do list. The command's name string, e.g. "echo"k. More than one name is allowed per command, so that localized names and shortcuts can be made available.-The first name in the list is considered the  primary nameN. When one name is shown, e.g. in help messages, it will be the primary name. šWhat to do in response to the command being triggered by an IRC user. The bot can send an IRC message back to the channel, or modify its state, or both.The returned value is in the  monad (it is really a» behind the scenes), which allows the bot to access the configuration and bot state, store and load data from files, communicate through the network (e.g. download RSS feeds) and more. Parameters: *Channel in which the command was triggered*Nickname of user who triggered the commandCommand parameters given!„Help string for the command, explaining it purpose, its parameters and its usage, possibly giving an example. May contain newlines."'Describes wrong usage of a bot command.#*Some other error, with a given description$DArgument in position <first-param> and value <second-param> invalid%(At least one of the arguments is invalid&=<first-param> arguments were given, instead of <second-param>'&The number of arguments given is wrong(,Configuration for the bot connection to IRC.*<Connection details, including nickname and optional password+List of channels to join, e.g. [" freepost", " rel4tion"]< =The bot configuration. The event source may find this useful.DThe bot's custom environment. The event source may find this useful.A non-blocking R; action which sends a given event to the processing queue.A non-blocking RD action which sends a given list of events to the processing queue. bSTUVWXYZ[\]^_cdefghijk !"#$%&'()*+Dlmnopqrs bSTUVWXYZ[\]^_cdefghijk !"#$%&'()*+   b _^]\[ZYXWVUTScdefghijk !"'&%$#()*+None,  !"#$%&'()*+,()*+"'&%$# !   None,Add quotes to a string.-"Optionally add quotes to a string..Format a list of labels.0putStrLn $ showNames (Just $ SingleQuotes False)", "["one", "two", "three"]'one', 'two', 'three',-."Optionally wrap labels with quotes/Separate between labels, e.g. spaces or newlineList of labels,-.,-.,-.None/ÿA default behavior definition which be convenienty overridden and extended using record syntax. It currently simply doesn't do anything (pings do get handled behind the scenes), but things like default responses and logging could be added in the future.0sTake a command name (without prefix) and a command set, and return the (leftmost) command which has that name, or t if there is no such command.1uFind a command in a list of command sets, using the given prefix character and command name. This is a shortcut for 2a which doesn't return the matched command set (for the cases you only need to find the command).2{Find a command in a list of command sets, using the given prefix character and command name. If the prefix isn't matched, t? is returned. If the prefix is matched but the command isn't, u v* the command set is returned. Otherwise, u w! the matched command is returned.3kTake a command prefix and a list of command sets, and return the (leftmost) set which has that prefex, or t if there is no such set.4ŻSearch for commands by testing a search string against their textual fields: Names and help strings. Each returned pair is a command and the prefix under which it was found.5Format a list of command names.69Format a list of the primary names of the given commands./012Command prefix to search forCommand name to search forCommand set in which to search345+Optionally prepend the prefix char to names&Optionally add quotes around the names5Whether to separate with commas (otherwise spaces)List of command names6.Optionally prepend the prefix char to names&Optionally add quotes around the names5Whether to separate with commas (otherwise spaces)List of commands/0123456/0123456/0123456None 7Fetch the bot configuration.8-Retrieve a function of the bot configuration.9"Fetch the bot behavior definition.:3Retrieve a function of the bot behavior definition.;0Fetch the bot environment, i.e. read-only state.<+Retrieve a function of the bot environment.x$Fetch the bot session socket handle.=8Fetch the current value of the state within the session.>MGet a specific component of the state, using a projection function supplied.?!Set the state within the session.@LUpdate the state to the result of applying a function to the current state. 789:;<x=>?@ 789:;<x=>?@ 789:;<x=>?@ NoneAöDisconnect from IRC by closing the bot's side of the connection. This function is mainly provided for completeness and cases of error. You should probably use the QUIT command of IRC to quit the network in a manner coordinated with the server.=After disconnection, make sure not to send more IRC commands.BBFinish the IRC session, asking the server to close the connection.C0Connect to an IRC server and run the bot sessionDnLog in as an IRC user and identify with the bot's nickname and password. This is the first thing to do after  botConnecting to the server.EÿIRC servers send PING messages at regular intervals to test the presence of an active client, at least if no other activity is detected on the connection. The server closes the connection automatically if a PONG response isn't sent from the client within a certain amount of time.ŚTherefore, an IRC client (both humans users and bots) usually listens to these PINGs and sends back PONG messages. This function sends a PONG. The parameters should simply be the ones received in the PING message.FJoin an IRC channel.GJoin one or more IRC channels.HnJoin the IRC channels listed in the configuration, without leaving any other channels the bot already joined.ILeave an IRC channel.JLeave one or more IRC channels.K&Leave all IRC channels the bot joined.L!Send a message to an IRC channel.źThis usually requires that the bot joins the channel first, because many channels have the +n flag set. This flag forbids sending a messages into a channel from outside it.M&Send a private message to an IRC user.NÀSend an IRC message to the server. This should only be used if the other wrappers don't provide what you need. If that's the case, it may be a good idea for reusability to add a new wrapper.AB.Optional message, e.g. the reason for quittingyCIRC configurationBot behavior definition(Custom bot environment (read-only state)Initial custom bot stateSession definitionDE Server nameOptional server to forward toF Channel nameOptional channel key (password)G"List of channels and optional keysHI Channel name5Optional part message, e.g. the reason for leavingJList of channel names5Optional part message, e.g. the reason for leavingKLThe channel name€The message to send. It may contain newlines, in which case it will be split into multiple messages and sent sequentially.MThe user's nickname€The message to send. It may contain newlines, in which case it will be split into multiple messages and sent sequentially.NABCDEFGHIJKLMNAByCDEFGHIJKLMN Nonez+Send the default response to an IRC channel{(Send the default response to an IRC userO3Send message explaining a failure to an IRC channelP0Send message explaining a failure to an IRC user|z{}~OTarget channel“User to whom to refer -> Char -- ^ Command prefix that was triggered -> String -- ^ Command name that was triggeredProblem indicationPƒTarget user -> Char -- ^ Command prefix that was triggered -> String -- ^ Command name that was triggeredProblem indicationz{OP|z{}~OPNoneABCDEFGHIJKLMNOPABCDEFGHIJKLMOPNNone 789:;<=>?@ 789:;<=>?@ NoneReact to an IRC event.€€€NoneQŻStart the bot and run its event loop. The bot will listen to messages from the IRC server and other provided sources, and will respond according to the behavior definitions.‚ƒ„…QIRC connection configuration"Behavior definition for IRC events&Additional event source threads to run,Handler for events coming from those sources(Custom bot environment (read-only state)'Initial state to hold in the backgroundQQ‚ƒ„…Q†        !"#$%%&'(()*+,-./01223456789:;<=>?@ABCDEFGHI J K L M N O P Q R S T U V W X YZ[\]^_`abcdefghij[klmnopqqrsstuvwxyzxy{xy|xy}xy~xyxy€xy‚ƒ„‚ƒ…‚†‡‚†ˆ‰ Š ‹ Œ  Ž   ‘ ’“”•–—irc-fun-bot-0.1.0.0Network.IRC.Fun.Bot.TypesNetwork.IRC.Fun.Bot.UtilNetwork.IRC.Fun.Bot.BehaviorNetwork.IRC.Fun.Bot.StateNetwork.IRC.Fun.Bot.ChatNetwork.IRC.Fun.Bot"Network.IRC.Fun.Bot.Internal.Types"Network.IRC.Fun.Bot.Internal.State!Network.IRC.Fun.Bot.Internal.Chat$Network.IRC.Fun.Bot.Internal.Failure"Network.IRC.Fun.Bot.Internal.Eventirc-fun-client-0.1.0.0Network.IRC.Fun.Client.IOpasswordnicktlsportserver ConnectionQuotes BackTicks DoubleQuotes SingleQuotes EventHandler EventSourceBehavior handleJoin handlePart handleQuit handleMsg handleBotMsg commandSetshandlePersonalMsghandleTopicChange handleNamesSession CommandSetprefixcommandsCommandnamesrespondhelpFailure OtherFail InvalidArg InvalidArgs WrongNumArgsN WrongNumArgsConfig connectionchannelsquote maybeQuote showNamesdefaultBehavior findCmdInSet findCmdInSetsfindCmdfindSet searchCmds listNameslistPrimaryNames askConfig askConfigS askBehavior askBehaviorSaskEnvaskEnvSgetState getStateSputState modifyState disconnectquitrunloginpong joinChannel joinMulti joinConfig partChannel partMultipartAll sendToChannel sendToUserputIrc failToChannel failToUserrunBotghc-prim GHC.TypesIONames OtherEvent TopicChangePersonalMessage BotCommand BotMessageNoticeMessageQuitPartJoinKickPing GHC.Classes>transformers-0.4.3.0Control.Monad.Trans.RWS.LazyRWSTEventBotStatepublicBotEnvconfigbehaviorhandlecustomirc-fun-messages-0.1.0.0'Network.IRC.Fun.Messages.Internal.TypesChannelPrivacyPublicPrivateSecret PrivilegeOperatorVoiceRegularbase Data.MaybeNothingJust Data.EitherLeftRight askHandle runSessiondefaultRespondToChandefaultRespondToUserdefaultResponsesuffixfailureDescription handleEvent matchEvent runCommandstartBot listenToEvent listenToIrc botSession