File Coverage

blib/lib/POE/Component/IRC/Constants.pm
Criterion Covered Total %
statement 12 12 100.0
branch n/a
condition n/a
subroutine 4 4 100.0
pod n/a
total 16 16 100.0


line stmt bran cond sub pod time code
1             package POE::Component::IRC::Constants;
2             $POE::Component::IRC::Constants::VERSION = '6.95';
3 79     79   537 use strict;
  79         330  
  79         3491  
4 79     79   428 use warnings FATAL => 'all';
  79         174  
  79         5828  
5              
6             require Exporter;
7 79     79   520 use base qw(Exporter);
  79         152  
  79         14092  
8             our @EXPORT_OK = qw(
9             PCI_REFCOUNT_TAG PRI_LOGIN PRI_HIGH PRI_NORMAL MSG_PRI MSG_TEXT
10             CMD_PRI CMD_SUB
11             );
12             our %EXPORT_TAGS = ( ALL => [@EXPORT_OK] );
13              
14             use constant {
15             # The name of the reference count P::C::I keeps in client sessions.
16 79         12875 PCI_REFCOUNT_TAG => 'P::C::I registered',
17              
18             # Message priorities.
19             PRI_LOGIN => 10, # PASS/NICK/USER messages must go first.
20             PRI_HIGH => 20, # KICK/MODE etc. is more important than chatter.
21             PRI_NORMAL => 30, # Random chatter.
22              
23             MSG_PRI => 0, # Queued message priority.
24             MSG_TEXT => 1, # Queued message text.
25              
26             # RCC: Since most of the commands are data driven, I have moved their
27             # event/handler maps here and added priorities for each data driven
28             # command. The priorities determine message importance when messages
29             # are queued up. Lower ones get sent first.
30             CMD_PRI => 0, # Command priority.
31             CMD_SUB => 1, # Command handler.
32 79     79   678 };
  79         225  
33              
34             1;
35              
36             =encoding utf8
37              
38             =head1 NAME
39              
40             POE::Component::IRC::Constants - Defines constants required by
41             L
42              
43             =head1 SYNOPSIS
44              
45             use POE::Component::IRC::Constants qw(:ALL);
46              
47             =head1 DESCRIPTION
48              
49             POE::Component::IRC::Constants defines constants required by
50             L and derived sub-classes.
51              
52             =head1 AUTHOR
53              
54             Chris Williams
55              
56             =head1 SEE ALSO
57              
58             L
59              
60             =cut