class documentation

Represent the ORM mapped attribute type for a "dynamic" relationship. The :class:`_orm.DynamicMapped` type annotation may be used in an :ref:`Annotated Declarative Table <orm_declarative_mapped_column>` mapping to indicate that the ``lazy="dynamic"`` loader strategy should be used for a particular :func:`_orm.relationship`. .. legacy:: The "dynamic" lazy loader strategy is the legacy form of what is now the "write_only" strategy described in the section :ref:`write_only_relationship`. E.g.:: class User(Base): __tablename__ = "user" id: Mapped[int] = mapped_column(primary_key=True) addresses: DynamicMapped[Address] = relationship( cascade="all,delete-orphan" ) See the section :ref:`dynamic_relationship` for background. .. versionadded:: 2.0 .. seealso:: :ref:`dynamic_relationship` - complete background :class:`.WriteOnlyMapped` - fully 2.0 style version

Method __get__ Undocumented
Method __set__ Undocumented
Class Variable __slots__ Undocumented

Inherited from TypingOnly (via _MappedAnnotationBase):

Method __init_subclass__ Undocumented
def __get__(self, instance: Optional[object], owner: Any) -> AppenderQuery[_T]: (source)

Undocumented

def __set__(self, instance: Any, value: typing.Collection[_T]): (source)

Undocumented