Jon Portnoy > IRC-Toolkit-0.072000 > IRC::Mode::Single

Download:
IRC-Toolkit-0.072000.tar.gz

Dependencies

Annotate this POD

View/Report Bugs
Module Version: 0.072000   Source   Latest Release: IRC-Toolkit-0.088001

NAME ^

IRC::Mode::Single - A single IRC mode change

SYNOPSIS ^

  my $mode = IRC::Mode::Single->new(
    '+', 'o', 'avenj'
  );

  my $flag = $mode->flag;
  my $mode = $mode->char;
  my $arg  = $mode->param;

DESCRIPTION ^

A simple ARRAY-type object representing a single mode change.

Can be used to turn "mode_to_array" in IRC::Toolkit::Modes mode ARRAYs into objects:

  for my $mset (@$mode_array) {
    my $this_mode = IRC::Mode::Single->new( @$mset );
    . . .
  }

Also see IRC::Mode::Set

new

Constructs a new mode change; expects at least a flag and mode.

as_string

Produces a mode string (with params attached) for this single mode change.

char

The mode character.

flag

The '-' or '+' flag for this mode change.

param

The parameter attached to the mode, if any.

AUTHOR ^

Jon Portnoy <avenj@cobaltirc.org>

syntax highlighting: