[Zodb-checkins] CVS: Zope3/src/zodb/code - class_.py:1.3
Jeremy Hylton
jeremy@zope.com
Mon, 30 Dec 2002 13:42:59 -0500
Update of /cvs-repository/Zope3/src/zodb/code
In directory cvs.zope.org:/tmp/cvs-serv29429
Modified Files:
class_.py
Log Message:
Add distinctive repr for persistent classes.
=== Zope3/src/zodb/code/class_.py 1.2 => 1.3 ===
--- Zope3/src/zodb/code/class_.py:1.2 Wed Dec 25 09:12:18 2002
+++ Zope3/src/zodb/code/class_.py Mon Dec 30 13:42:59 2002
@@ -287,6 +287,10 @@
return
super(PersistentClassMetaClass, cls).__delattr__(attr)
+ def __repr__(cls):
+ return "<persistent class %s.%s>" % (cls.__module__,
+ cls.__name__)
+
def __getstate__(cls):
dict = {}
for k, v in cls.__dict__.items():