psycopg2/sandbox/pbool.py

13 lines
349 B
Python
Raw Normal View History

class B(object):
def __init__(self, x):
if x: self._o = True
else: self._o = False
def __getattribute__(self, attr):
print("ga called", attr)
return object.__getattribute__(self, attr)
def _sqlquote(self):
2017-11-28 11:25:09 +03:00
if self._o:
return 'It is True'
else:
return 'It is False'