katteba/uuidshortener

将32字符的UUID十六进制字符串转换为Base32短字符串,反之亦然。

1.0.1 2016-10-31 09:17 UTC

This package is auto-updated.

Last update: 2024-08-28 07:37:26 UTC


README

Latest Stable Version Build Status Maintainability License

由Obj-C原创

将32字符的UUID十六进制字符串转换为Base32短字符串,反之亦然。

安装

composer require katteba/uuidshortener

使用

压缩UUID

<?php

use Katteba\UUID\UUIDShortener;

$uuid = '...';
$compressedUuid = UUIDShortener::encode($uuid);

从紧凑表示恢复原始UUID

<?php

use Katteba\UUID\UUIDShortener;

$compressedUuid = '...';
$uuid = UUIDShortener::decode($compressedUuid);