php-extended/php-uuid-object

An implementation of the php-uuid-interface library


Keywords
php, object, uuid, implementation
License
MIT

Documentation

php-uuid-object

An implementation of the php-uuid-interface library

Installation

The installation of this library is made via composer. Download composer.phar from their website. Then add to your composer.json :

	"require": {
		...
		"php-extended/php-uuid-object": "^2"
		...
	}

Then run php composer.phar update to install this library. The autoloading of all classes of this library is made through composer's autoloader.

Basic Usage

This library may be used the following way :

To parse an uuid :


use PhpExtended\Uuid\Uuid;

$uuid = Uuid::parse('<put here your uuid string>');

To generate an uuid :


$v1 = Uuid::generateV1();
$v3 = Uuid::generateV3($uuidNamespace, $stringName);
$v4 = Uuid::generateV4();
$v5 = Uuid::generateV5($uuidNamespace, $stringName);

License

MIT (See license file).