Types¶
The models/types subpackage contains enumerations and shared type definitions used across the domain layer and
adapters.
Base Types¶
Foundational type definitions and base enumerations shared across the application.
archipy.models.types.base_types.BaseType ¶
Bases: Enum
Base class for creating enumerated types with custom values.
This class extends the Enum class to allow custom values for enum members.
Source code in archipy/models/types/base_types.py
archipy.models.types.base_types.FilterOperationType ¶
Bases: Enum
Enumeration of filter operations for querying or filtering data.
This enum defines the types of operations that can be used in filtering, such as equality checks, comparisons, and string matching.
Attributes:
| Name | Type | Description |
|---|---|---|
EQUAL |
str
|
Represents an equality check. |
NOT_EQUAL |
str
|
Represents a non-equality check. |
LESS_THAN |
str
|
Represents a less-than comparison. |
LESS_THAN_OR_EQUAL |
str
|
Represents a less-than-or-equal comparison. |
GREATER_THAN |
str
|
Represents a greater-than comparison. |
GREATER_THAN_OR_EQUAL |
str
|
Represents a greater-than-or-equal comparison. |
IN_LIST |
str
|
Represents a check for membership in a list. |
NOT_IN_LIST |
str
|
Represents a check for non-membership in a list. |
LIKE |
str
|
Represents a case-sensitive string pattern match. |
ILIKE |
str
|
Represents a case-insensitive string pattern match. |
STARTS_WITH |
str
|
Represents a check if a string starts with a given prefix. |
ENDS_WITH |
str
|
Represents a check if a string ends with a given suffix. |
CONTAINS |
str
|
Represents a check if a string contains a given substring. |
IS_NULL |
str
|
Represents a check if a value is null. |
IS_NOT_NULL |
str
|
Represents a check if a value is not null. |
Source code in archipy/models/types/base_types.py
archipy.models.types.base_types.FilterOperationType.EQUAL
class-attribute
instance-attribute
¶
archipy.models.types.base_types.FilterOperationType.NOT_EQUAL
class-attribute
instance-attribute
¶
archipy.models.types.base_types.FilterOperationType.LESS_THAN
class-attribute
instance-attribute
¶
archipy.models.types.base_types.FilterOperationType.LESS_THAN_OR_EQUAL
class-attribute
instance-attribute
¶
archipy.models.types.base_types.FilterOperationType.GREATER_THAN
class-attribute
instance-attribute
¶
archipy.models.types.base_types.FilterOperationType.GREATER_THAN_OR_EQUAL
class-attribute
instance-attribute
¶
archipy.models.types.base_types.FilterOperationType.IN_LIST
class-attribute
instance-attribute
¶
archipy.models.types.base_types.FilterOperationType.NOT_IN_LIST
class-attribute
instance-attribute
¶
archipy.models.types.base_types.FilterOperationType.LIKE
class-attribute
instance-attribute
¶
archipy.models.types.base_types.FilterOperationType.ILIKE
class-attribute
instance-attribute
¶
archipy.models.types.base_types.FilterOperationType.STARTS_WITH
class-attribute
instance-attribute
¶
archipy.models.types.base_types.FilterOperationType.ENDS_WITH
class-attribute
instance-attribute
¶
archipy.models.types.base_types.FilterOperationType.CONTAINS
class-attribute
instance-attribute
¶
archipy.models.types.base_types.FilterOperationType.IS_NULL
class-attribute
instance-attribute
¶
archipy.models.types.base_types.FilterOperationType.IS_NOT_NULL
class-attribute
instance-attribute
¶
options: show_root_toc_entry: false heading_level: 3
Email Types¶
Enumeration of email content types and delivery classifications.
archipy.models.types.email_types.EmailAttachmentType ¶
Bases: StrEnum
Enum representing different types of email attachments.
This enum defines the types of attachments that can be included in an email, such as files, base64-encoded data, URLs, or binary data.
Attributes:
| Name | Type | Description |
|---|---|---|
FILE |
str
|
Represents a file attachment. |
BASE64 |
str
|
Represents a base64-encoded attachment. |
URL |
str
|
Represents an attachment referenced by a URL. |
BINARY |
str
|
Represents raw binary data as an attachment. |
Source code in archipy/models/types/email_types.py
archipy.models.types.email_types.EmailAttachmentType.FILE
class-attribute
instance-attribute
¶
archipy.models.types.email_types.EmailAttachmentType.BASE64
class-attribute
instance-attribute
¶
archipy.models.types.email_types.EmailAttachmentType.URL
class-attribute
instance-attribute
¶
archipy.models.types.email_types.EmailAttachmentType.BINARY
class-attribute
instance-attribute
¶
archipy.models.types.email_types.EmailAttachmentDispositionType ¶
Bases: StrEnum
Enum representing attachment disposition types.
This enum defines how an email attachment should be displayed or handled, such as being treated as a downloadable attachment or displayed inline.
Attributes:
| Name | Type | Description |
|---|---|---|
ATTACHMENT |
str
|
Represents an attachment that should be downloaded. |
INLINE |
str
|
Represents an attachment that should be displayed inline. |
Source code in archipy/models/types/email_types.py
options: show_root_toc_entry: false heading_level: 3
Language Type¶
Enumeration of supported language codes for internationalisation.
archipy.models.types.language_type.LanguageType ¶
Bases: StrEnum
Enum representing supported languages for error messages.
This enum defines the languages that are supported for generating or displaying error messages. Each language is represented by its ISO 639-1 code.
Attributes:
| Name | Type | Description |
|---|---|---|
FA |
str
|
Represents the Persian language (ISO 639-1 code: 'fa'). |
EN |
str
|
Represents the English language (ISO 639-1 code: 'en'). |
Source code in archipy/models/types/language_type.py
options: show_root_toc_entry: false heading_level: 3
Sort Order Type¶
Enumeration of sort order directions (ascending, descending).
archipy.models.types.sort_order_type.SortOrderType ¶
Bases: Enum
Enumeration of sorting order types.
This enum defines the types of sorting orders that can be applied to data, such as ascending or descending.
Attributes:
| Name | Type | Description |
|---|---|---|
ASCENDING |
str
|
Represents sorting in ascending order. |
DESCENDING |
str
|
Represents sorting in descending order. |
Source code in archipy/models/types/sort_order_type.py
options: show_root_toc_entry: false heading_level: 3
Time Interval Unit Type¶
Enumeration of time interval units (seconds, minutes, hours, days) used in scheduling and rate limiting.
archipy.models.types.time_interval_unit_type.TimeIntervalUnitType ¶
Bases: StrEnum
Enum representing units of time for intervals.
This enum defines standard time units used to specify intervals or durations in
time-based operations, such as scheduling, timeouts, or pagination. Each value
represents a unit of time, from seconds to years, and inherits from str to allow
seamless integration with string-based APIs or databases.
Source code in archipy/models/types/time_interval_unit_type.py
archipy.models.types.time_interval_unit_type.TimeIntervalUnitType.SECONDS
class-attribute
instance-attribute
¶
archipy.models.types.time_interval_unit_type.TimeIntervalUnitType.MINUTES
class-attribute
instance-attribute
¶
archipy.models.types.time_interval_unit_type.TimeIntervalUnitType.HOURS
class-attribute
instance-attribute
¶
archipy.models.types.time_interval_unit_type.TimeIntervalUnitType.DAYS
class-attribute
instance-attribute
¶
archipy.models.types.time_interval_unit_type.TimeIntervalUnitType.WEEKS
class-attribute
instance-attribute
¶
archipy.models.types.time_interval_unit_type.TimeIntervalUnitType.MONTHS
class-attribute
instance-attribute
¶
archipy.models.types.time_interval_unit_type.TimeIntervalUnitType.YEAR
class-attribute
instance-attribute
¶
options: show_root_toc_entry: false heading_level: 3