kumwe / business-definition
Immutable business definitions, bounded formula semantics, validation and compatibility.
Requires
- php: ^8.5
- php-64bit: *
- ext-mbstring: *
- kumwe/localization: 0.1.1
- kumwe/sequence: 0.2.1
- psr/container: ^2.0
- ramsey/uuid: ^4.9
Requires (Dev)
- ext-zip: *
- laminas/laminas-servicemanager: ^4.0
- phpstan/phpstan: ^2.1
- phpstan/phpstan-deprecation-rules: ^2.0
- phpstan/phpstan-strict-rules: ^2.0
- phpunit/phpunit: ^12.0 || ^13.0
- squizlabs/php_codesniffer: ^4.0
Suggests
None
Provides
None
Conflicts
None
Replaces
None
This package is auto-updated.
Last update: 2026-09-12 15:02:39 UTC
README
Immutable business definitions, typed bounded formula ASTs, canonical profiles,
structural validation, compatibility plans and portable registries under Kumwe\BusinessDefinition.
Installation
Requires 64-bit PHP 8.5 with ext-mbstring. Install an exact pre-1.0 release:
composer require kumwe/business-definition:0.1.2
Composer declares the exact Kumwe dependency versions. Published versions are linked from the badge; default-branch CI reports package checks, not Core integration or independent release verification.
Usage and Core contract
Construct BusinessDefinitionValidator($fieldTypes, $fieldConfigurationAdmission)
with a host-owned FieldConfigurationAdmission implementation, or register the
package's ConfigProvider and bind that mandatory port before resolving a validator.
It must enforce the selected SDK presentation profile; there is no permissive default.
The standalone definition example constructs and validates
a definition, checks canonical bytes and compatibility, and demonstrates an explicit
fixture admission policy. Run it from a source checkout with composer examples.
The container example shows actual Laminas composition.
Core retains publication, persistence, trusted generation selection, authorization, lifecycle, invalidation and recovery. This package describes formula semantics; it does not execute PHP formulas. Runtime execution uses the separately verified Computation/Engine/PHP extension chain. See host integration and semantic boundaries.
Documentation
- Public API and architecture
- Formula profile and security/compatibility
- Test ownership and consumer release record
- Release process and changelog
Development
composer install composer check
The complete gate covers dependency identity, security audit, syntax/docblocks, architecture, manifests/API, production autoload, examples, coding standards, static analysis, behavior/conformance, test ownership and a clean no-dev archive consumer. CI runs PHP 8.5 on Linux. Dependabot proposes grouped weekly Composer updates; each update runs the same gate before review and rebase merge.
Published tags remain fixed. Consumers independently verify exact releases and their
dependency graph, then run their own integration checks. Changes on main are shipped
in a subsequent release. Licensed under Apache-2.0.