aeat.domain.prorrata_register._protocols module¶
Domain-level repository Protocol for the cross-period IVA prorrata register.
Application-layer code that persists or loads the ProrrataRegister
depends on ProrrataRegisterRepositoryProtocol, not on the concrete
adapter-backed ProrrataRegisterRepository. This keeps the domain layer
free of adapter imports while still providing a typed port surface.
- class ProrrataRegisterRepositoryProtocol(*args, **kwargs)[source]¶
Bases:
ProtocolNarrow domain-facing repository contract for the prorrata register.
Any object that provides
loadandto_secure_object_writeover the singletonProrrataRegistersatisfies this protocol. The concrete secure-object-backed implementation isProrrataRegisterRepository.- load()[source]¶
Return the persisted register or an empty register if absent.
- Return type:
- Returns:
The
ProrrataRegisterloaded from storage.
- to_secure_object_write(register)[source]¶
Return the
SecureObjectWriteforregisterwithout committing it.- Return type:
- Parameters:
register (ProrrataRegister)