承接 timitao/value-object 相关项目开发

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

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

timitao/value-object

Composer 安装命令:

composer require timitao/value-object

包简介

README 文档

README

License Latest Stable Version Total Downloads Scrutinizer Code Quality

Why

This library provides typed Value Objects in the spirit of Domain-Driven Design: immutable, compared by value and by type. It keeps contracts (interfaces) separate from implementations, offers both Required (non-null) and Nullable variants, and has no framework dependency—you can depend only on the contract package or use the default implementations.

Installation

composer require timitao/value-object

Usage

Extend one of the standard value object classes and use equals() for type-safe value comparison (same concrete class and same value):

use TimiTao\ValueObject\Standard\Required\AbstractClass\ValueObject\StringValueObject;

final class Title extends StringValueObject {}

$a = new Title('Hello');
$b = new Title('Hello');
$c = new Title('World');

$a->equals($b); // true — same class, same value
$a->equals($c); // false — same class, different value

Architecture decision records

  1. Record architecture decisions
  2. Strict code style
  3. Use of Beberlei/assert library
  4. Split nullable and standard in 2 namespaces
  5. Change facade for Beberlei extension uses

Versioning

Staring version 1.0.0, will follow Semantic Versioning v2.0.0.

Contributors

  • Tomasz Kunicki TimiTao [lead developer]

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: BSD-3-Clause
  • 更新时间: 2018-09-14

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固