File Coverage

blib/lib/Data/ParseBinary/Stream/Wrapper.pm
Criterion Covered Total %
statement 18 36 50.0
branch n/a
condition n/a
subroutine 7 15 46.6
pod n/a
total 25 51 49.0


line stmt bran cond sub pod time code
1 5     5   89 use strict;
  5         10  
  5         181  
2 5     5   27 use warnings;
  5         7  
  5         2773  
3            
4             package Data::ParseBinary::Stream::WrapperReader;
5             our @ISA = qw{Data::ParseBinary::Stream::Reader Data::ParseBinary::Stream::WrapperBase};
6            
7             __PACKAGE__->_registerStreamType("Wrap");
8            
9             sub new {
10 0     0   0 my ($class, $sub_stream) = @_;
11 0         0 my $self = bless { }, $class;
12 0         0 $self->_warping($sub_stream);
13 0         0 return $self;
14             }
15            
16 0     0   0 sub ReadBytes { my $self = shift; $self->{ss}->ReadBytes(@_); }
  0         0  
17 0     0   0 sub ReadBits { my $self = shift; $self->{ss}->ReadBits(@_); }
  0         0  
18 0     0   0 sub isBitStream { my $self = shift; $self->{ss}->isBitStream(@_); }
  0         0  
19 0     0   0 sub seek { my $self = shift; $self->{ss}->seek(@_); }
  0         0  
20 0     0   0 sub tell { my $self = shift; $self->{ss}->tell(@_); }
  0         0  
21            
22             package Data::ParseBinary::Stream::WrapperWriter;
23             our @ISA = qw{Data::ParseBinary::Stream::Writer Data::ParseBinary::Stream::WrapperBase};
24            
25             __PACKAGE__->_registerStreamType("Wrap");
26            
27             sub new {
28 30     30   48 my ($class, $sub_stream) = @_;
29 30         99 my $self = bless { }, $class;
30 30         117 $self->_warping($sub_stream);
31 30         116 return $self;
32             }
33            
34 149     149   177 sub WriteBytes { my $self = shift; $self->{ss}->WriteBytes(@_); }
  149         439  
35 9     9   10 sub WriteBits { my $self = shift; $self->{ss}->WriteBits(@_); }
  9         22  
36 63     63   81 sub Flush { my $self = shift; return $self->{ss} }
  63         141  
37 9     9   10 sub isBitStream { my $self = shift; $self->{ss}->isBitStream(@_); }
  9         22  
38 0     0     sub seek { my $self = shift; $self->{ss}->seek(@_); }
  0            
39 0     0     sub tell { my $self = shift; $self->{ss}->tell(@_); }
  0            
40            
41             1;