Download the PHP package phine/compact without Composer

On this page you can find all versions of the php package phine/compact. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package compact

Compact

Build Status Coverage Status Latest Stable Version Total Downloads

A PHP library for compacting the contents of files.

Requirement

Installation

Via Composer:

$ composer require "phine/compact=~1.0"

Usage

The Compact library provides a consistent way of compacting files and their contents. The purpose of the library is simply to reduce the size of the contents without affecting how it is used. For example, compacting a JSON file would involve removing any excess whitespace that was used for "pretty printing".

Assuming we had this in example.json:

The contents would then be compacted to:

Bundled Compactors

The library also includes the following compactor classes:

Creating a Compactor

The library includes an interface that all bundled classes implement. An abstract class is also included, which all bundled compactor classes extend. When you create your own compactor class, you will want to extend the Phine\Compact\AbstractCompact class.

When extending the AbstractCompact class, the compactFile() method will already be implemented for you. It will rely on the compactContents() method to compact the contents after it has been read from the file.

Please considering adding your compactor class to the wiki.

Collections

If you need to manage multiple compactors, the library offers a Collection class. In addition to the class, an interface is provided so that different implementations can be supported.

Documentation

You can find the API documentation here.

License

This library is available under the MIT license.


All versions of compact with dependencies

PHP Build Version
Package Version
Requires php Version >=5.3.3
phine/exception Version ~1.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package phine/compact contains the following files

Loading the files please wait ....