The Perl and Raku Conference 2025: Greenville, South Carolina - June 27-29 Learn more
|
sub new {
my ( $class , $name ) = @_ ;
my $self = $class ->SUPER::new;
$self ->{filename} = "" ;
$self ->{bytes} = 0;
$self ->{ length } = 0;
}
sub read_in_byte_array {
my $self = shift ;
my $self ->{filename} = shift ;
$self ->{ length } = ;
}
sub get_byte {
my $self = shift ;
my $index = shift ;
return ( $self ->{bytes} >> ( $index -1)*4 - $self ->{bytes} >> $index *4);
}
sub get_byte_interval {
my $self = shift ;
my $i = shift ;
my $j = shift ;
return ( $self ->{bytes} >> $j *4 - $self ->{bytes} >> $i *4);
}
1;
|