承接 phpgt/ulid 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

phpgt/ulid

最新稳定版本:v1.2.1

Composer 安装命令:

composer require phpgt/ulid

包简介

Unique, lexicographically sortable identifiers.

README 文档

README

Create a new Ulid() anywhere in your application, and you have a stringable object that can be used as the primary key in a database. Ulid strings look something like 01G2J6MYN0PGC5Q21W9C or can be prefixed with a type like CUSTOMER_01G2J6MYN0PGC5Q21W9C. They are cryptographically pseudo-random, and sort so that newer Ulids compare "greater than" older Ulids.

This solves the problems exposed with working with auto-incrementing integer primary keys, which are predictable and difficult to work with in distributed databases.

Build status Code quality Code coverage Current version PHP.Gt/Ulid documentation

Example usage:

use Gt\Ulid\Ulid;

$exampleDataSource->create(new Person(
	new Ulid("pet"),
	name: "Cody",
	age: 5,
));

Proudly sponsored by

JetBrains Open Source sponsorship program

JetBrains logo.

统计信息

  • 总下载量: 1.75k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 0
  • 依赖项目数: 2
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2022-05-08