/[webpac2]/trunk/lib/WebPAC/Input/Test.pm
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /trunk/lib/WebPAC/Input/Test.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 796 by dpavlin, Sun Feb 4 12:42:43 2007 UTC revision 797 by dpavlin, Sun Feb 4 13:28:30 2007 UTC
# Line 4  use warnings; Line 4  use warnings;
4  use strict;  use strict;
5    
6  use WebPAC::Input;  use WebPAC::Input;
7    use WebPAC::Common;
8  use base qw/WebPAC::Common/;  use base qw/WebPAC::Common/;
9    use Data::Dump qw/dump/;
10    
11  =head1 NAME  =head1 NAME
12    
# Line 36  Setup test record Line 38  Setup test record
38    
39  Setup optional size  Setup optional size
40    
41    $WebPAC::Input::Test::Size = 42;    $WebPAC::Input::Test::size = 42;
42    
43  =head1 FUNCTIONS  =head1 FUNCTIONS
44    
# Line 71  Return record with ID C<$mfn> from datab Line 73  Return record with ID C<$mfn> from datab
73    
74    my $rec = $isis->fetch_rec( $mfn );    my $rec = $isis->fetch_rec( $mfn );
75    
76  Second argument, C<filter_coderef> is ignored.  Second argument, C<filter_coderef> will be assigned to
77    C<WebPAC::Input::Test::filer_coderef>.
78    
79  =cut  =cut
80    
81  my $rec;  our $rec;
82    our $filter_coderef;
83    
84  sub fetch_rec {  sub fetch_rec {
85          my $self = shift;          my $self = shift;
86    
87          my ($mfn, $filter_coderef) = @_;          my $mfn = shift;
88            $filter_coderef = shift;
89    
90          $self->_get_logger()->info("mfn = $mfn");          $self->_get_logger()->debug("mfn = $mfn rec = ", dump($rec));
91    
92          return $rec;          return $rec;
93  }  }
# Line 109  Return number of records in database Line 114  Return number of records in database
114    
115  =cut  =cut
116    
117  my $size = 1;  our $size = 1;
118    
119  sub size {  sub size {
120          my $self = shift;          my $self = shift;
121          $self->_get_logger()->info("size = $size");          $self->_get_logger()->debug("size = $size");
122          return $size;          return $size;
123  }  }
124    

Legend:
Removed from v.796  
changed lines
  Added in v.797

  ViewVC Help
Powered by ViewVC 1.1.26