CodeListGenerator
in package
FinalYes
Generates the code list files (resources/codelists/*.json) from the official EN 16931 Schematron rules (BR-CL-*), as shipped with the KoSIT validator configuration.
Table of Contents
Constants
- LISTS : array<string|int, mixed> = ['BR-CL-01' => 'invoice-type-codes', 'BR-CL-03'...
- Rule codes and the code list names used by the package.
Methods
- defaultTarget() : string
- generate() : array<string, int>
- generatePeppol() : array<string, int>
- Generates the Peppol code lists (PEPPOL-EN16931-CL…) that are narrower than the EN 16931 lists, from the Peppol BIS Billing 3.0 Schematron (PEPPOL-EN16931-UBL.sch).
Constants
LISTS
Rule codes and the code list names used by the package.
public
array<string|int, mixed>
LISTS
= ['BR-CL-01' => 'invoice-type-codes', 'BR-CL-03' => 'currency-codes', 'BR-CL-06' => 'tax-point-date-codes-cii', 'BR-CL-07' => 'object-identifier-schemes', 'BR-CL-08' => 'note-subject-codes', 'BR-CL-10' => 'icd-schemes', 'BR-CL-13' => 'item-classification-schemes', 'BR-CL-14' => 'country-codes', 'BR-CL-16' => 'payment-means-codes', 'BR-CL-17' => 'vat-category-codes', 'BR-CL-19' => 'allowance-reason-codes', 'BR-CL-20' => 'charge-reason-codes', 'BR-CL-22' => 'vatex-codes', 'BR-CL-23' => 'unit-codes', 'BR-CL-24' => 'mime-codes', 'BR-CL-25' => 'eas-codes']
Methods
defaultTarget()
public
static defaultTarget() : string
Return values
stringgenerate()
public
generate(string $xslPath[, string|null $target = null ]) : array<string, int>
Parameters
- $xslPath : string
- $target : string|null = null
Return values
array<string, int> —code list name => number of codes
generatePeppol()
Generates the Peppol code lists (PEPPOL-EN16931-CL…) that are narrower than the EN 16931 lists, from the Peppol BIS Billing 3.0 Schematron (PEPPOL-EN16931-UBL.sch).
public
generatePeppol(string $schematronPath[, string|null $target = null ]) : array<string, int>
Parameters
- $schematronPath : string
- $target : string|null = null
Return values
array<string, int> —code list name => number of codes