cadrumo.domain.modelos.modelo_fact_context module

Typed governed-fact resolution context for modelo reduction calculations.

class ModeloFactResolutionContext(authority, filing_period, devengo_date)[source]

Bases: object

Authority and explicit filing/devengo coordinates for modelo facts.

Parameters:
authority: GovernedFactSource
filing_period: date
devengo_date: date
integer(fact_id)[source]

Resolve an integer-valued modelo governed fact.

Return type:

int

Parameters:

fact_id (str)

decimal(fact_id)[source]

Resolve a Decimal-valued modelo governed fact.

Return type:

Decimal

Parameters:

fact_id (str)

resolved_decimal(fact_id)[source]

Resolve a Decimal modelo fact while preserving its provenance.

Return type:

ResolvedScalarFact

Parameters:

fact_id (str)

resolved_scalar(fact_id)[source]

Resolve a modelo fact on its declared temporal coordinate.

Return type:

ResolvedScalarFact

Parameters:

fact_id (str)