File Coverage

blib/lib/Child/Link.pm
Criterion Covered Total %
statement 20 20 100.0
branch n/a
condition n/a
subroutine 8 8 100.0
pod 0 2 0.0
total 28 30 93.3


line stmt bran cond sub pod time code
1             package Child::Link;
2 20     20   91 use strict;
  20         23  
  20         438  
3 20     20   59 use warnings;
  20         160  
  20         460  
4              
5 20     20   62 use Child::Util;
  20         20  
  20         5102  
6 20     20   304 use Carp qw/croak/;
  20         30  
  20         3141  
7              
8             add_accessors qw/pid/;
9              
10 2     2 0 122 sub ipc { undef }
11              
12 4     4   1648 sub _no_ipc { croak "Child was created without IPC support" }
13              
14             sub new {
15 51     51 0 154 my $class = shift;
16 51         156 my ( $pid ) = @_;
17 51         705 return bless( { _pid => $pid }, $class );
18             }
19              
20             {
21 20     20   112 no strict 'refs';
  20         20  
  20         1495  
22             *{__PACKAGE__ . '::' . $_} = \&_no_ipc
23             for qw/autoflush flush read say write/;
24             }
25              
26             1;
27              
28             =head1 NAME
29              
30             Child::Link - Base class for objects that link child and parent processes.
31              
32             =head1 HISTORY
33              
34             Most of this was part of L intended for use in the L
35             project. Fennec is being broken into multiple parts, this is one such part.
36              
37             =head1 FENNEC PROJECT
38              
39             This module is part of the Fennec project. See L for more details.
40             Fennec is a project to develop an extendable and powerful testing framework.
41             Together the tools that make up the Fennec framework provide a potent testing
42             environment.
43              
44             The tools provided by Fennec are also useful on their own. Sometimes a tool
45             created for Fennec is useful outside the greater framework. Such tools are
46             turned into their own projects. This is one such project.
47              
48             =over 2
49              
50             =item L - The core framework
51              
52             The primary Fennec project that ties them all together.
53              
54             =back
55              
56             =head1 AUTHORS
57              
58             Chad Granum L
59              
60             =head1 COPYRIGHT
61              
62             Copyright (C) 2010 Chad Granum
63              
64             Child is free software; Standard perl licence.
65              
66             Child is distributed in the hope that it will be useful, but WITHOUT
67             ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
68             FOR A PARTICULAR PURPOSE. See the license for more details.