MCPcopy
hub / github.com/sqlalchemy/sqlalchemy / _clone

Method _clone

lib/sqlalchemy/sql/elements.py:5440–5451  ·  view source on GitHub ↗
(self, detect_subquery_cols=False, **kw)

Source from the content-addressed store, hash-verified

5438 return super().entity_namespace
5439
5440 def _clone(self, detect_subquery_cols=False, **kw):
5441 if (
5442 detect_subquery_cols
5443 and self.table is not None
5444 and self.table._is_subquery
5445 ):
5446 clone = kw.pop("clone")
5447 table = clone(self.table, **kw)
5448 new = table.c.corresponding_column(self)
5449 return new
5450
5451 return super()._clone(**kw)
5452
5453 @HasMemoized_ro_memoized_attribute
5454 def _from_objects(self) -> List[FromClause]:

Callers 4

_cloneMethod · 0.45
typed_expressionMethod · 0.45

Calls 3

cloneFunction · 0.70
popMethod · 0.45
corresponding_columnMethod · 0.45

Tested by

no test coverage detected