2017 © Pedro Peláez
 

library registry

This package contains a basic implementation for a registry.

image

dbeurive/registry

This package contains a basic implementation for a registry.

  • Friday, April 29, 2016
  • by dbeurive
  • Repository
  • 1 Watchers
  • 0 Stars
  • 8 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 2 Versions
  • 0 % Grown

The README.md

Description

This package implements a simple registry., (*1)

Installation

From the command line:, (*2)

composer require dbeurive/tree

From your composer.json file:, (*3)

{
    "require": {
        "dbeurive/tree": "1.0.*"
    }
}

API documentation

The detailed documentation of the API can be extracted from the code by using PhpDocumentor. The file phpdoc.xml contains the required configuration for PhpDocumentor. To generate the API documentation, just move into the root directory of this package and run PhpDocumentor from this location., (*4)

Note:, (*5)

Since all the PHP code is documented using PhpDoc annotations, you should be able to exploit the auto completion feature from your favourite IDE. If you are using Eclipse, NetBeans or PhPStorm, you probably won’t need to consult the generated API documentation., (*6)

Synopsis

Register an entry:, (*7)

$value = 10;
dbeurive\Registry\Registry::register('YourEntry', $value);

Register an entry and declare it as constant:, (*8)

$value = 10;
dbeurive\Registry\Registry::register('YourEntry', $value, true);

Get the value of a registered entry:, (*9)

dbeurive\Registry\Registry::get('YourEntry');

Change the value of a registered entry:, (*10)

$newValue = 20;
dbeurive\Registry\Registry::set('YourEntry', $newValue);

Test if an entry is registered:, (*11)

if (dbeurive\Registry\Registry::isRegistered('YourEntry')) { ... }

Test if an entry is declared as constant:, (*12)

if (dbeurive\Registry\Registry::isConstant('YourEntry')) { ... }

Examples

Unit tests are good examples., (*13)

The Versions

29/04 2016

dev-master

9999999-dev

This package contains a basic implementation for a registry.

  Sources   Download

MIT

by Denis BEURIVE

registry

29/04 2016

1.0.0

1.0.0.0

This package contains a basic implementation for a registry.

  Sources   Download

MIT

by Denis BEURIVE

registry