THE ORIONIS API
Build with clarity.
Explore the building blocks of an async-first Python framework. Every module, class, and method — connected, searchable, and ready to build with.
class documentation
Soft delete behavior shared by every model.
A model opts in by declaring soft_deletes = True together with a
deleted_at column. Deleting then stamps that column instead of
removing the row, queries exclude stamped rows by default, and the
row can be brought back with
orionis.orm.soft_deletes.SoftDeletesMixin.restore.
| Async Method | _perform |
Stamp the soft delete column of the persisted row. |
| Async Method | force |
Delete the row permanently, ignoring soft deletes. |
| Async Method | restore |
Bring a soft deleted row back by clearing its delete stamp. |
| Method | trashed |
Report whether the instance is currently soft deleted. |
| Class Variable | __slots__ |
Declare that this class introduces no additional instance slots. |
Stamp the soft delete column of the persisted row.
| Parameters | |
timestamp:datetime.datetime | Value written into the soft delete column. |
| Returns | |
bool | True when the row was stamped. |
| Raises | |
orionis.database.QueryException | If the statement fails to execute. |
Delete the row permanently, ignoring soft deletes.
| Returns | |
bool | True when a row was removed, False for unsaved models, missing rows, or when a listener vetoed the operation. |
| Raises | |
orionis.database.QueryException | If the statement fails to execute. |
Bring a soft deleted row back by clearing its delete stamp.
| Returns | |
bool | True when the row was restored, False when the model does not soft delete, was never persisted, or a listener vetoed the operation, or no stored row matched. |
| Raises | |
orionis.database.QueryException | If the statement fails to execute. |
Report whether the instance is currently soft deleted.
| Returns | |
bool | True when the soft delete column carries a timestamp. |