id_translation.fetching.types#
Types related to translation fetching.
Module Attributes
Key operation types for fetching. |
|
Key operation types for fetchers. |
Classes
|
Instructions passed from an |
|
A source and the IDs to fetch from it. |
- class FetchInstruction(source, placeholders, required, ids, task_id, enable_uuid_heuristics)[source]#
Bases:
Generic[SourceType,IdType]Instructions passed from an
AbstractFetcherto an implementation.- enable_uuid_heuristics#
Improves matching when
UUID-like IDs are in use.Implementations which have no UUID heuristics may silently ignore this flag.
- property fetch_all#
If
True, retrieve all available data.
- ids#
Unique IDs to fetch translations for.
- placeholders#
All desired placeholders in preferred order.
- required#
Placeholders that must be included in the response.
- source#
Where to fetch from.
- task_id#
Used for logging purposes.
- class IdsToFetch(source, ids)[source]#
Bases:
Generic[SourceType,IdType]A source and the IDs to fetch from it.
- ids#
Unique IDs to fetch translations for.
- source#
Where to fetch from.
- Operation = typing.Literal['INITIALIZE_SOURCES'] | typing.Literal['FETCH', 'FETCH_ALL']#
Key operation types for fetchers.