[Zope3-checkins] CVS: Zope3/src/zope/i18n - messageid.py:1.5

Stephan Richter srichter at cosmos.phy.tufts.edu
Tue Aug 12 18:12:59 EDT 2003


Update of /cvs-repository/Zope3/src/zope/i18n
In directory cvs.zope.org:/tmp/cvs-serv2243/src/zope/i18n

Modified Files:
	messageid.py 
Log Message:
Made MessageID pickable.


=== Zope3/src/zope/i18n/messageid.py 1.4 => 1.5 ===
--- Zope3/src/zope/i18n/messageid.py:1.4	Tue Apr 15 17:17:48 2003
+++ Zope3/src/zope/i18n/messageid.py	Tue Aug 12 17:12:54 2003
@@ -42,6 +42,13 @@
         self.mapping = {}
         return self
 
+    def __getstate__(self):
+        return unicode(self), self.domain, self.default, self.mapping
+
+    def __setstate__(self, (ustr, domain, default, mapping)):
+        self.__new__(ustr, domain, default)
+        self.mapping = mapping
+
 
 class MessageIDFactory:
     """Factory for creating MessageIDs."""




More information about the Zope3-Checkins mailing list