ORIONIS API REFERENCE

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

String-backed enumeration column.

Method __init__ Construct an enum.
Class Variable __slots__ Undocumented
def __init__(self, *enums: str, name: str | None = None, create_constraint: bool = False, native_enum: bool = True, length: int | None = None, validate_strings: bool = False): (source)

Construct an enum.

Parameters
*enums:strAllowed string values, at least one is required.
name:str or None, optionalName of the enumerated database type.
create_constraint:bool, optionalWhen emulating a non-native enum, also build a CHECK constraint against the allowed values.
native_enum:bool, optionalWhether to use the backend's native ENUM type.
length:int or None, optionalCustom VARCHAR length for non-native enumerations.
validate_strings:bool, optionalWhether to validate string literals against allowed values.
Returns
NoneThis method does not return a value.
Raises
ValueErrorIf no values are provided or any value is not a string.
__slots__: tuple = (source)

Undocumented