Kaguya v0.6.5 Kaguya.Util

Link to this section Summary

Functions

Sets MODE +b on mask in chan where mask can be !@vhost.com This bans a user from chan

Looks up a channel’s pid and returns it if it exists, nil otherwise

Returns the docstring for a handler in a module

Sends a WHOIS query to a server for a nick and returns a Kaguya.Core.User struct if it was succesful. Otherwise nil is returned

Sends the IRC server the JOIN command

Kicks user from chan

Kicks user from chan with the reason reason

Loads a module

Sends the IRC server the PART command

Unloads then loads a module

Sends the NICK command to the IRC server, with the given nick

Sends a NOTICE to a recipient on the IRC server

Sends a PRIVMSG to a recipient on the IRC server

Sends the PASS command to the IRC server with the given password

Sends the USER command to the IRC server, with the given name, and an optional realname param

Sets MODE mode on chan. Example: chan is “#sekrit” mode is “+s”

Sets MODE mode on trailing in chan. Example: chan is “#sekrit”, mode is “+b” and trailing is “baduser”

Sets MODE -b on mask in chan where mask can be !@vhost.com This unbans a user from chan

Unloads a module

Link to this section Functions

Link to this function ban(chan, mask)

Sets MODE +b on mask in chan where mask can be !@vhost.com This bans a user from chan.

Link to this function color(foreground)
Link to this function color(foreground, background)
Link to this function getChanPid(channel)

Looks up a channel’s pid and returns it if it exists, nil otherwise.

Link to this function getDocs(module, handler)

Returns the docstring for a handler in a module

Sends a WHOIS query to a server for a nick and returns a Kaguya.Core.User struct if it was succesful. Otherwise nil is returned.

Link to this function joinChan(channel)

Sends the IRC server the JOIN command.

Link to this function kick(chan, user)

Kicks user from chan.

Link to this function kick(reason, chan, user)

Kicks user from chan with the reason reason.

Link to this function loadModule(module)

Loads a module.

Link to this function partChan(channel)

Sends the IRC server the PART command.

Link to this function reloadModule(module)

Unloads then loads a module.

Sends the NICK command to the IRC server, with the given nick.

Link to this function sendNotice(message, recipient)

Sends a NOTICE to a recipient on the IRC server.

Link to this function sendPM(message, recipient)

Sends a PRIVMSG to a recipient on the IRC server.

Link to this function sendPass(password)

Sends the PASS command to the IRC server with the given password

Link to this function sendUser(user, realname \\ nil)

Sends the USER command to the IRC server, with the given name, and an optional realname param.

Link to this function setMode(chan, mode)

Sets MODE mode on chan. Example: chan is “#sekrit” mode is “+s”

This will make the #sekrit channel secret.

Link to this function setMode(chan, mode, trailing)

Sets MODE mode on trailing in chan. Example: chan is “#sekrit”, mode is “+b” and trailing is “baduser”

This will set +b on baduser!@

Link to this function unban(chan, mask)

Sets MODE -b on mask in chan where mask can be !@vhost.com This unbans a user from chan.

Link to this function unloadModule(module)

Unloads a module.