Skip to content
CAI
Software that uses CAICheck a score

ytake/valueobjects

64.2

Adequate · 22 September 2026

5.7k

lines of production code

PHP

primary language

7

measurements over time

CAI band scale
CAI trend line
CAI lens gauges

What this system is

This system is a PHP library that provides a comprehensive collection of immutable value objects for common data types, including dates, times, temperatures, numbers, money, and web components. It enforces type safety and consistent behavior for these domains through specialized classes and interfaces. The project also establishes a robust development environment with continuous integration, static analysis, and extensive unit testing.

Features

Add value objects for date, time, and climate

Introduced new value objects for handling date and time components, including Date, DateTime, DateTimeWithTimeZone, Time, Year, Month, MonthDay, Hour, Minute, Second, and WeekDay. Also added value objects for temperature (Celsius, Fahrenheit, Kelvin) and relative humidity. These classes provide type-safe, immutable wrappers around native PHP types, enabling safer manipulation of dates, times, and physical measurements within the application.

(repo-wide) · high confidence

Add value objects for numbers and money

Introduced new value objects for handling numeric and monetary data: \Integer\, \Natural\, \Real\, and \Complex\ in the \ValueObjects\\Number\ namespace, along with \Currency\, \CurrencyCode\, and \Money\ in the \ValueObjects\\Money\ namespace. These classes provide immutable wrappers around PHP's native types, ensuring type safety and consistent behavior for financial calculations and general number operations.

src/Number · high confidence

Add value objects for web components

Introduced new value objects for web-related data, including Url, Domain, Hostname, IPAddress, EmailAddress, QueryString, Path, SchemeName, and PortNumber, along with their respective interfaces and null implementations. These classes provide structured, immutable representations of web components, enabling safer handling of URLs, domains, IP addresses, and other web-specific data types.

src/Web · high confidence

Initial project scaffolding and CI configuration

The repository was initialized with a comprehensive set of configuration files to support development and continuous integration. This includes build scripts for Travis CI and Coveralls, coding standards for PHP-CS-Fixer and PHPCS, and static analysis tools like Scrutinizer and PHPMD. Additionally, the project added a PSR-2 compliant style guide, a PHPUnit configuration for test coverage, and updated the README with installation instructions and build status badges.

(repo-wide) · high confidence

Test coverage

Added unit tests for value objects

Added comprehensive test suites for the library's value objects, including temperature, date/time, geography, money, and number types. The tests verify core behaviors such as construction, value comparison, and native type conversion, with specific attention to locale-dependent float validation.

tests · high confidence

Dependencies

Initial release of the ValueObjects PHP library

The project introduces a new PHP library named 'ytake/valueobjects', designed to provide a collection of immutable value objects for developers. The package specifies a minimum PHP 7.0 requirement and includes dependencies for UUID generation (ramsey/uuid), currency handling (moneyphp/money), enumerations (marc-mabe/php-enum), geospatial tools (league/geotools), and validation (laminas/laminas-validator). The entry also establishes the development environment with PHPUnit, code coverage, and static analysis tools.

(dependencies) · high confidence

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

How this codebase got here

This is the PUBLIC form of this artifact. Findings are listed in full, but the details of SECURITY findings — which rule fired, in which file, on which line, and how to fix it — are deliberately withheld, and any secret-scanner results are excluded entirely. Where detail is absent here it was REMOVED FOR PUBLICATION; it is not missing from the analysis. The complete artifact is available from the repository owner.

Score

  • CAI 65 → 64 (-0.7)
  • Rubric changed (rubric-2026.08.19 → rubric-2026.09.15) — scores are not directly comparable.

Lenses

  • Code Health 100 → 99 (-0.7)
  • Architecture 100 → 92 (-7.9)
  • Maturity 54 → 54 (+0.0)
  • Readiness 57 → 53 (-4.0)
  • Security 85 → 97 (+11.4)

Resolved (10)

  • Coverage not included — suite not readable by the collector
  • Dependency hygiene not measured — dependency manifest found but not parsed for hygiene
  • High: security finding (details withheld)
  • High: security finding (details withheld)
  • No exposed public API
  • Test reliability not included
  • early-stage repository — too few commits for a meaningful bus factor
  • early-stage repository — too little history to judge knowledge freshness
  • git history depth insufficient
  • git history depth insufficient

New (56)

  • Dependency hygiene PARTLY measured — Composer dependencies read, no committed lock to grade for currency
  • Documentation: no installation or build instructions (README.md)
  • Documentation: no usage examples (README.md)
  • Duplicated block (24 lines × 4) (src/DateTime/Hour.php)
  • Duplicated block (38 lines × 2) (src/DateTime/Hour.php)
  • Duplicated block (5 lines × 2) (src/DateTime/TimeZone.php)
  • Duplicated block (5 lines × 2) (src/Web/IPv4Address.php)
  • Duplicated block (5 lines × 3) (src/Web/FragmentIdentifier.php)
  • Duplicated block (5 lines × 5) (src/Enum/Enum.php)
  • Duplicated block (6 lines × 5) (src/DateTime/DateTime.php)
  • Duplicated block (7 lines × 2) (src/Web/EmailAddress.php)
  • High: security finding (details withheld)
  • High: security finding (details withheld)
  • Medium: security finding (details withheld)
  • Medium: security finding (details withheld)
  • No assertions: testAlmostValidDateException (tests/DateTime/DateTest.php)
  • No assertions: testDifferentLocaleWithDifferentDecimalCharacter (tests/Climate/CelsiusTest.php)
  • No assertions: testDifferentLocaleWithDifferentDecimalCharacter (tests/Climate/FahrenheitTest.php)
  • No assertions: testDifferentLocaleWithDifferentDecimalCharacter (tests/Climate/KelvinTest.php)
  • No assertions: testDifferentLocaleWithDifferentDecimalCharacter (tests/Geography/CoordinateTest.php)
  • …and 36 more

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

Survey your own repository

ytake/valueobjects was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.

About this page

  • The score is its most recent published measurement, taken on 22 September 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
  • Measured at commit 23ad90904bf2fa188cf23da9b183fee706b8ee2f — the exact code this score is about.
  • Scored under rubric-2026.09.15 — the same rubric and the same method as every other entry in this index.
  • Measured by watchdog.canine.dev using codehealth-analyzer preprod-821afab8930d.