class Annotated(object):
Known subclasses: sqlalchemy.sql.elements.AnnotatedColumnElement
, sqlalchemy.sql.selectable.AnnotatedFromClause
clones a SupportsAnnotated and applies an 'annotations' dictionary.
Unlike regular clones, this clone also mimics __hash__() and __cmp__() of the original element so that it takes its place in hashed collections.
A reference to the original element is maintained, for the important reason of keeping its hash value current. When GC'ed, the hash value may be reused, causing conflicts.
Note
The rationale for Annotated producing a brand new class, rather than placing the functionality directly within ClauseElement, is performance. The __hash__() method is absent on plain ClauseElement which leads to significantly reduced function call overhead, as the use of sets and dictionaries against ClauseElement objects is prevalent, but most are not "annotated".
Method | __eq__ |
Undocumented |
Method | __hash__ |
Undocumented |
Method | __init__ |
Undocumented |
Method | __new__ |
Undocumented |
Method | __reduce__ |
Undocumented |
Method | _annotate |
Undocumented |
Method | _clone |
Undocumented |
Method | _compiler_dispatch |
Undocumented |
Method | _deannotate |
Undocumented |
Method | _with_annotations |
Undocumented |
Class Variable | _is_column_operators |
Undocumented |
Instance Variable | __dict__ |
Undocumented |
Instance Variable | __element |
Undocumented |
Instance Variable | _annotations |
Undocumented |
Instance Variable | _hash |
Undocumented |
Property | _constructor |
Undocumented |
Property | entity_namespace |
Undocumented |
sqlalchemy.sql.elements.AnnotatedColumnElement
, sqlalchemy.sql.selectable.AnnotatedFromClause
Undocumented
sqlalchemy.sql.elements.AnnotatedColumnElement
Undocumented