2017 © Pedro Peláez
 

library lib-archive

Abstraction library for (de)compression of archives.

image

ride/lib-archive

Abstraction library for (de)compression of archives.

  • Thursday, October 13, 2016
  • by ride-user
  • Repository
  • 8 Watchers
  • 0 Stars
  • 39 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 7 Versions
  • 0 % Grown

The README.md

Ride: Archive Library

Ride library for abstraction of file archiving., (*1)

What's In This Library

Archive

The Archive interface is used to implement a compression algorithm. You can use it to compress files into an archive or to decompress an archive to your file system., (*2)

There are 2 implementations provided: * PharArchive * ZipArchive, (*3)

Code Sample

Check this code sample to see how to use this library:, (*4)

<?php

use ride\library\archive\ZipArchive;
use ride\library\system\file\FileSystem;

function createArchive(FileSystem $fileSystem) {
    // create the archive
    $archiveFile = $fileSystem->getTemporaryFile();
    $archive = new ZipArchive($archiveFile);

    // compress single file in the root of the archive
    $file = $fileSystem->getFile('/my/file');
    $archive->compress($file);

    // compress multiple files in a folder in the archive
    $files = array(
        $fileSystem->getFile('/my/second-file'),
        $fileSystem->getFile('/my/third-file'),
    );
    $archive->compress($files, 'path/in/archive'); 

    // we're done here
    return $archiveFile;
}

Installation

You can use Composer to install this library., (*5)

composer require ride/lib-archive

The Versions

13/10 2016

dev-develop

dev-develop

Abstraction library for (de)compression of archives.

  Sources   Download

MIT

The Requires

 

by Joris Vandeweerd

13/10 2016

dev-master

9999999-dev

Abstraction library for (de)compression of archives.

  Sources   Download

MIT

The Requires

 

by Joris Vandeweerd

13/10 2016

1.0.0

1.0.0.0

Abstraction library for (de)compression of archives.

  Sources   Download

MIT

The Requires

 

by Joris Vandeweerd

01/04 2015

0.3.0

0.3.0.0

Abstraction library for (de)compression of archives.

  Sources   Download

The Requires

 

by Joris Vandeweerd

01/04 2015

0.2.0

0.2.0.0

Abstraction library for (de)compression of archives.

  Sources   Download

The Requires

 

by Joris Vandeweerd

09/09 2014

0.1.1

0.1.1.0

Abstraction library for (de)compression of archives.

  Sources   Download

The Requires

 

by Joris Vandeweerd

01/05 2014

0.1.0

0.1.0.0

Abstraction library for (de)compression of archives.

  Sources   Download

The Requires

 

by Joris Vandeweerd