This package is abandoned and no longer maintained. The author suggests using the norse-blue/scalar-objects package instead.

axelitus's Acre common classes.

dev-master 2012-11-08 22:18 UTC

This package is auto-updated.

Last update: 2022-02-01 12:21:14 UTC


Acre Common is a sub-package of Acre. It contains classes for the common usage, mainly extensions and tools for basic types (strings, numbers, etc.). For more information about the Acre initiative please visit this link.

Package Information


As a code reuse initiative, this package should follow some standards so it can be easily used by anyone who wants to. Recently there has been an initiative to standardize the chunks of code everyone is building so the wheel must not be reinvented everytime someone needs to do something. There's a group PHP-FIG (Framework Interop Group) that's behind this initiative of allowing the built libraries to be interchangeable between frameworks and systems.

There are already some standards marked as accepted (final): PSR-0, PSR-1 and PSR-2.

This package is PSR-2 compliant.

Being PSR-2 compliant means this package can be easily installed by using Composer from the Packagist package archive. Just follow the instructions in section How to install.


  • Num: Tools for numeric types.
  • Str: Tools for string types.

How to install

To install this package and use it in your app just follow these instructions (if you haven't read the documentation from Composer please do so before you continue):

  1. Download composer if you haven't already done so (use your preferred method):

    curl -s | php

  2. Place a require statement inside your composer.json file replacing <version> with the desired version:

    "require": { "axelitus/acre-common": "" }

  3. Run the composer installer to resolve dependencies and download the packages:

    php composer.phar install

  4. In order to use the packages you have to load the autoloader that was generated by composer:

    require 'vendor/autoload.php';

  5. Finally just use the package classes as needed: