AOL-TOC

 view release on metacpan or  search on metacpan

SFLAP.pm  view on Meta::CPAN

  }

}

sub callback {
  my ($self, $chan, @args) = @_;
  my $func;

  for $func (@{$self->{callback}{$chan}}) {
    #print ("callback() calling a func $func for $chan fd $self->{fd}..\n");
    eval { &{$func} ($self, @args, @{$self->{callback}{$func}}) };
  }

  return;
}

sub new {
  my ($tochost, $authorizer, $port, $nickname) = @_;
  my $self;
  my $ipaddr;

TOC.pm  view on Meta::CPAN


  return;
}


sub callback {
  my ($self, $event, @args) = @_;
  my $func;

  for $func (@{$self->{callback}{$event}}) {
    eval { &{$func} ($self, @args, @{$self->{callback}{$func}}) };
  }

  return;
}


sub clear_callbacks {
  my ($self) = @_;
  my $k; 
 

tocbot/tocbot.pl  view on Meta::CPAN


if ( ! -f "tocbot.config" ) {
  die "tocbot: no config file!\n";
}

require "tocbot.config";

for $name (@tocbot_modules) {
  print "tocbot: loading module $name\n";
  require "$name".".pl";
  eval { &{$name . "_init"} };
}

open(client_config, "toc.config");
$client_config = join('', <client_config>);
close(client_config);

$toc = AOL::TOC::new($tocbot_config{tochost}, $tocbot_config{authorizer},
                     $tocbot_config{port},
                     $tocbot_config{nickname}, $tocbot_config{password});
#$toc->set_debug(9);

tocbot/tocbot.pl  view on Meta::CPAN

sub tocbot_register_command {
  my ($cmd, $func, @args) = @_;

  print "Registered command '$cmd'\n";
  $tocbot_commands{$cmd}  = $func;
}

sub tocbot_exec_command {
  my ($cmd, @args) = @_;

  eval { &{$tocbot_commands{$cmd}} (@args) };
}



( run in 0.805 second using v1.01-cache-2.11-cpan-5a3173703d6 )