cadrumo.domain.calculations.registry.iva_deduction_catalogue module

Typed projection of the governed IVA-deduction applicability catalogue.

class IvaDeductionCatalogue(declarations, kinds, authorities)[source]

Bases: object

The dated, typed projection of fact 0085.

Parameters:
declarations: Mapping[str, str]
kinds: tuple[IvaDeductionFactKind, ...]
authorities: tuple[IvaDeductionEvidenceAuthority, ...]
require_kind(value)[source]

Return a kind only when fact 0085 declares it.

Return type:

IvaDeductionFactKind

Parameters:

value (object)

require_authority(value)[source]

Return an evidence authority only when fact 0085 declares it.

Return type:

IvaDeductionEvidenceAuthority

Parameters:

value (object)

projection(key)[source]

Return a fact-0085 kind projection, preserving no Python catalogue.

Return type:

frozenset[IvaDeductionFactKind]

Parameters:

key (str)

required_authority(kind)[source]

Return the registry-declared evidence family for kind.

Return type:

IvaDeductionEvidenceAuthority

Parameters:

kind (IvaDeductionFactKind)

authority_for_role(role)[source]

Return a named authority projection declared by fact 0085.

Return type:

IvaDeductionEvidenceAuthority

Parameters:

role (str)

property ordinary_kinds: tuple[IvaDeductionFactKind, ...]

Return authored kind order excluding the owner-only projection.

resolve_iva_deduction_catalogue(*, effective_date=None, authority=None)[source]

Resolve all fifteen IVA-deduction axis tokens from fact 0085.

Return type:

IvaDeductionCatalogue

Parameters:
require_iva_deduction_fact_kind(value, *, effective_date=None, authority=None)[source]

Project one IVA deduction kind through fact 0085.

Return type:

IvaDeductionFactKind

Parameters:
require_iva_deduction_evidence_authority(value, *, effective_date=None, authority=None)[source]

Project one evidence authority through fact 0085.

Return type:

IvaDeductionEvidenceAuthority

Parameters:
iva_deduction_fact_kinds(*, effective_date=None, authority=None)[source]

Return all non-owner-only deduction kinds in registry order.

Return type:

tuple[IvaDeductionFactKind, ...]

Parameters:
is_iva_deduction_kind(value, projection_key, *, effective_date=None, authority=None)[source]

Test membership in one fact-0085 projection without local values.

Return type:

bool

Parameters:
invoice_evidence_authority(*, effective_date=None, authority=None)[source]

Return the registry-declared authority for invoice-linked evidence.

Return type:

IvaDeductionEvidenceAuthority

Parameters: