Quittio 0.3 API

CountryPack
in

Everything that differs between countries.

A country pack may only add or tighten rules; it never relaxes EN 16931 rules.

Table of Contents

Methods

addressFormatter()  : AddressFormatter
Formats postal addresses by the conventions of the country, e.g. for the address window.
buyerCountryRules()  : array<int, Rule>
Rules applied when the pack's country is the buyer's country of a cross-border invoice.
code()  : string
ISO 3166-1 alpha-2 code, e.g. "DE".
correctionPolicy()  : CorrectionPolicy
Cancellation and correction strategies and titles; see CorrectionPolicy for who uses what.
defaults()  : CountryDefaults
Defaults of the country: locale, paper, letter layout, payment QR code and default VAT presets, plus informational values (currency, time zone, profile); see CountryDefaults.
dunningLaw()  : DunningLaw
Statutory late payment rules. Informational metadata for applications, e.g. to compute fees and default interest for DocumentBuilder::fee() and interest(); the core does not apply them.
exporters()  : array<int, Exporter>
Export formats the pack declares (e.g. DATEV). Informational metadata for applications; Quittio runs no exporter.
formatRules()  : array<int, FormatRule>
Format choice for domestic invoices.
legalTexts()  : LegalTextCatalog
Legal and informational texts of the country by key and locale. Informational metadata for applications and the pack's own presets and rules; the core adds none of them to an invoice by itself.
letterLayouts()  : array<string, LetterLayout>
Letter layouts by name (e.g. din5008a, din5008b); CountryDefaults::$letterLayout selects the default.
mandatoryOutput()  : MandatoryFieldList
Values that the PDF of $invoice must show by law; the mandatory field guard checks that the template printed them.
numberingRules()  : NumberingRules
Numbering requirements; the Managed layer applies pattern and resets (see NumberingRules).
paymentQr()  : PaymentQrGenerator|null
Payment QR code generator of the country, used for the type "auto" unless CountryDefaults::$paymentQr is "none" (an application's generator registered with Quittio::setPaymentQrGenerator() comes first); null = the EPC GiroCode for "girocode".
profiles()  : array<int, Profile>
National profiles, e.g. XRechnung.
readers()  : array<int, FormatReader>
Readers for national formats. Quittio::read() and validateFile() try them after the CII and UBL readers, for every registered pack; return new instances on every call (readers keep the state of one document).
retention()  : RetentionRule
Retention period of issued invoices; the Managed layer stores the end of it.
rules()  : array<int, Rule>
Additional validation rules (L3) applied when the pack is the leading pack.
taxPresets()  : TaxPresetCollection
Tax presets of the country by key (e.g. "de.small_business"). Informational metadata for applications, e.g. to offer them in a form or to resolve a stored LineVat::$presetKey; the core does not apply it: lines take a preset with LineBuilder::vat().
translationPath()  : string|null
Directory with translation files ({locale}/{group}.php) of the pack, if any.

Methods

buyerCountryRules()

Rules applied when the pack's country is the buyer's country of a cross-border invoice.

public buyerCountryRules() : array<int, Rule>
Return values
array<int, Rule>

code()

ISO 3166-1 alpha-2 code, e.g. "DE".

public code() : string
Return values
string

defaults()

Defaults of the country: locale, paper, letter layout, payment QR code and default VAT presets, plus informational values (currency, time zone, profile); see CountryDefaults.

public defaults() : CountryDefaults
Return values
CountryDefaults

dunningLaw()

Statutory late payment rules. Informational metadata for applications, e.g. to compute fees and default interest for DocumentBuilder::fee() and interest(); the core does not apply them.

public dunningLaw() : DunningLaw
Return values
DunningLaw

exporters()

Export formats the pack declares (e.g. DATEV). Informational metadata for applications; Quittio runs no exporter.

public exporters() : array<int, Exporter>
Return values
array<int, Exporter>

legalTexts()

Legal and informational texts of the country by key and locale. Informational metadata for applications and the pack's own presets and rules; the core adds none of them to an invoice by itself.

public legalTexts() : LegalTextCatalog
Return values
LegalTextCatalog

letterLayouts()

Letter layouts by name (e.g. din5008a, din5008b); CountryDefaults::$letterLayout selects the default.

public letterLayouts() : array<string, LetterLayout>
Return values
array<string, LetterLayout>

paymentQr()

Payment QR code generator of the country, used for the type "auto" unless CountryDefaults::$paymentQr is "none" (an application's generator registered with Quittio::setPaymentQrGenerator() comes first); null = the EPC GiroCode for "girocode".

public paymentQr() : PaymentQrGenerator|null
Return values
PaymentQrGenerator|null

readers()

Readers for national formats. Quittio::read() and validateFile() try them after the CII and UBL readers, for every registered pack; return new instances on every call (readers keep the state of one document).

public readers() : array<int, FormatReader>
Return values
array<int, FormatReader>

rules()

Additional validation rules (L3) applied when the pack is the leading pack.

public rules() : array<int, Rule>
Return values
array<int, Rule>

taxPresets()

Tax presets of the country by key (e.g. "de.small_business"). Informational metadata for applications, e.g. to offer them in a form or to resolve a stored LineVat::$presetKey; the core does not apply it: lines take a preset with LineBuilder::vat().

public taxPresets() : TaxPresetCollection
Return values
TaxPresetCollection

translationPath()

Directory with translation files ({locale}/{group}.php) of the pack, if any.

public translationPath() : string|null
Return values
string|null
On this page

Search results