diff options
| author | Matthias Urlichs <matthias@urlichs.de> | 2014-05-19 03:08:42 +0200 |
|---|---|---|
| committer | Matthias Urlichs <matthias@urlichs.de> | 2014-05-19 03:08:42 +0200 |
| commit | 611d529537194dd95a3114d627aaf4eab449a8cb (patch) | |
| tree | 9d20b7465b1bf636f2da121c90bde8e90c6f7eee /examples | |
| parent | 460465a8749aecff761e1c81c77d7c23e8672789 (diff) | |
| download | sqlalchemy-pr/92.tar.gz | |
Add a _proxyImpl helper classpr/92
formalchemy does the following:
if isinstance(self._impl, ScalarAttributeImpl) or self._impl.__class__.__name__ == '_ProxyImpl': # ProxyImpl is a one-off class for each synonym, can't import it
# normal property, mapped to a single column from the main table
prop = getattr(self._property, '_proxied_property', None)
if prop is None:
prop = self._property
return tuple(prop.local_columns)
With this patch, this test can be replaced with
if isinstance(self._impl, (ScalarAttributeImpl,ProxyImpl):
…
Diffstat (limited to 'examples')
0 files changed, 0 insertions, 0 deletions
