FieldMatrix
in package
Field metadata of all DTOs, derived from the mapping attributes (single source for profile validation, documentation and coverage reports).
Table of Contents
Methods
- businessTerm() : string|null
- Business term of a field, resolved for shared structures (Address, Contact, Period) from the business term of the parent field, e.g. BT-55 for the country code of the buyer address (BG-8).
- fields() : array<string, FieldDefinition>
- level() : ProfileLevel
- Lowest profile level that carries a field where it is used: its own level (EN 16931 without a Level attribute, EXTENDED for fields of EXTENDED only), raised to the level of the parent field, because a part is written only together with its parent. E.g. the address parts of BASIC WL inside the seller address (BG-5, MINIMUM) stay BASIC WL, the country code (BT-40, MINIMUM) stays MINIMUM; inside the buyer address (BG-8, BASIC WL) the country code (BT-55) is BASIC WL.
Methods
businessTerm()
Business term of a field, resolved for shared structures (Address, Contact, Period) from the business term of the parent field, e.g. BT-55 for the country code of the buyer address (BG-8).
public
static businessTerm(class-string $class, string $property, string|null $parentTerm) : string|null
Parameters
- $class : class-string
- $property : string
- $parentTerm : string|null
-
business term of the parent field (e.g. BG-8), null at the top level
Return values
string|nullfields()
public
static fields(class-string $class) : array<string, FieldDefinition>
Parameters
- $class : class-string
Return values
array<string, FieldDefinition>level()
Lowest profile level that carries a field where it is used: its own level (EN 16931 without a Level attribute, EXTENDED for fields of EXTENDED only), raised to the level of the parent field, because a part is written only together with its parent. E.g. the address parts of BASIC WL inside the seller address (BG-5, MINIMUM) stay BASIC WL, the country code (BT-40, MINIMUM) stays MINIMUM; inside the buyer address (BG-8, BASIC WL) the country code (BT-55) is BASIC WL.
public
static level(class-string $class, string $property[, ProfileLevel|null $parentLevel = null ]) : ProfileLevel
Parameters
- $class : class-string
- $property : string
- $parentLevel : ProfileLevel|null = null
-
effective level of the parent field, null at the top level