OrderedViewCollection
- class app.portfolio.collections.ordered_view.collection.OrderedViewCollection[source]
Bases:
Collection
,Generic
Inheritance Diagram for OrderedViewCollection
Methods
__init__
([data])get_content_type
(cls[, source])Resolve and cache the concrete parent argument defined by the descriptor.
get_core_schema
(source, handler)item_sort_key
(item)serialize
(value)validate_and_coerce
(value, *[, source])Attributes
- __init__(data: Iterable | None = None, /) None [source]
- Parameters:
data (Iterable | None)
- Return type:
None
- classmethod get_content_type(cls: type[T], source: type[T] | None = None, **kwargs: Unpack[GetConcreteParentArgumentKwargs]) type[R]
Resolve and cache the concrete parent argument defined by the descriptor.
The descriptor caches the result per owning class via
instance_lru_cache()
so repeated introspections remain constant time.- Raises:
GenericsError – If the underlying parent argument cannot be resolved to a concrete type.
- Parameters:
cls (type[T])
source (type[T] | None)
kwargs (Unpack[GetConcreteParentArgumentKwargs])
- Return type:
type[R]
- abstractmethod classmethod get_core_schema(source, handler) InvalidSchema | AnySchema | NoneSchema | BoolSchema | IntSchema | FloatSchema | DecimalSchema | StringSchema | BytesSchema | DateSchema | TimeSchema | DatetimeSchema | TimedeltaSchema | LiteralSchema | MissingSentinelSchema | EnumSchema | IsInstanceSchema | IsSubclassSchema | CallableSchema | ListSchema | TupleSchema | SetSchema | FrozenSetSchema | GeneratorSchema | DictSchema | AfterValidatorFunctionSchema | BeforeValidatorFunctionSchema | WrapValidatorFunctionSchema | PlainValidatorFunctionSchema | WithDefaultSchema | NullableSchema | UnionSchema | TaggedUnionSchema | ChainSchema | LaxOrStrictSchema | JsonOrPythonSchema | TypedDictSchema | ModelFieldsSchema | ModelSchema | DataclassArgsSchema | DataclassSchema | ArgumentsSchema | ArgumentsV3Schema | CallSchema | CustomErrorSchema | JsonSchema | UrlSchema | MultiHostUrlSchema | DefinitionsSchema | DefinitionReferenceSchema | UuidSchema | ComplexSchema [source]
- Return type:
InvalidSchema | AnySchema | NoneSchema | BoolSchema | IntSchema | FloatSchema | DecimalSchema | StringSchema | BytesSchema | DateSchema | TimeSchema | DatetimeSchema | TimedeltaSchema | LiteralSchema | MissingSentinelSchema | EnumSchema | IsInstanceSchema | IsSubclassSchema | CallableSchema | ListSchema | TupleSchema | SetSchema | FrozenSetSchema | GeneratorSchema | DictSchema | AfterValidatorFunctionSchema | BeforeValidatorFunctionSchema | WrapValidatorFunctionSchema | PlainValidatorFunctionSchema | WithDefaultSchema | NullableSchema | UnionSchema | TaggedUnionSchema | ChainSchema | LaxOrStrictSchema | JsonOrPythonSchema | TypedDictSchema | ModelFieldsSchema | ModelSchema | DataclassArgsSchema | DataclassSchema | ArgumentsSchema | ArgumentsV3Schema | CallSchema | CustomErrorSchema | JsonSchema | UrlSchema | MultiHostUrlSchema | DefinitionsSchema | DefinitionReferenceSchema | UuidSchema | ComplexSchema
- classmethod get_journalled_type() type[JournalledOrderedViewSet] [source]
- Return type:
- item_sort_key(item: T) SupportsRichComparison [source]
- Parameters:
item (T)
- Return type:
SupportsRichComparison