MCPcopy Create free account
hub / github.com/sqlalchemy/sqlalchemy / __invert__

Method __invert__

lib/sqlalchemy/sql/elements.py:746–752  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

744 return compiled_sql, extracted_params, cache_hit
745
746 def __invert__(self):
747 # undocumented element currently used by the ORM for
748 # relationship.contains()
749 if hasattr(self, "negation_clause"):
750 return self.negation_clause
751 else:
752 return self._negate()
753
754 def _negate(self) -> ClauseElement:
755 # TODO: this code is uncovered and in all likelihood is not included

Callers

nothing calls this directly

Calls 1

_negateMethod · 0.95

Tested by

no test coverage detected