Jon Portnoy > Bot-Cobalt-0.014 > Bot::Cobalt::IRC::Server

Download:
Bot-Cobalt-0.014.tar.gz

Dependencies

Annotate this POD

View/Report Bugs
Module Version: 0.014   Source   Latest Release: Bot-Cobalt-0.016002

NAME ^

Bot::Cobalt::IRC::Server - An IRC server context

SYNOPSIS ^

  ## Get a Bot::Cobalt::IRC::Server object from Bot::Cobalt::Core
  my $server = $core->get_irc_context( $context );  
  
  if ( $server->connected ) {
    my $casemap = $server->casemap;
    
    . . .
  }

DESCRIPTION ^

Represents an IRC server context.

Bot::Cobalt::Core stores a server context object for every configured context; it can be retrieved using get_irc_context.

Attributes

The following attributes are available:

name

The server name.

Note that this is the server we connected to or intend to connect to; not necessarily the announced name of a connected server.

connected

A boolean value indicating whether or not this context is marked as connected.

In the case of core-managed contexts, this is set by Bot::Cobalt::IRC.

connectedat

The time (epoch seconds) that the server context was marked as connected.

prefer_nick

The preferred/configured nickname for this context.

irc

The actual IRC object for this configured context; this will typically be a POE::Component::IRC subclass.

casemap

The available CASEMAPPING value for this server.

See "get_irc_casemap" in Bot::Cobalt::Manual::Plugins

maxmodes

The maximum number of modes allowed in a single mode change command.

If the server does not announce MAXMODES, the default is 3.

maxtargets

The maximum number of targets allowed for a single message as specified by MAXTARGETS.

Useful for combining message sends to multiple channels, for example.

Methods

lowercase

  my $lower = $server->lowercase($string);

Lowercase a string via "lc_irc" in IRC::Utils using the currently-configured "casemap".

uppercase

The opposite of "lowercase".

AUTHOR ^

Jon Portnoy <avenj@cobaltirc.org>

http://www.cobaltirc.org

syntax highlighting: