Help for this page

Select Code to Download


  1. or download this
    my $tar_obj = Archive::Tar->new;
    $tar_obj->read( "my.tar")
    
    # or just: my $tar_obj = Archive::Tar->new( "my.tar" );
    
  2. or download this
    use Archive::Tar;
    
    ...
        my $filedata = $tar->get_content( $filename );
        # do other stuff...
    }
    
  3. or download this
    use Archive::Tar;
    
    ...
        my $data = $file->get_content;  # same as above, but no searching 
    +involved
        # do other stuff...
    }
    
  4. or download this
    my %cksums;
    
    ...
          $cksum{$file->cksum} = undef; # keep track of cksums
       }
    }