[Zope3-checkins] CVS: Zope3/src/zope/publisher/interfaces - __init__.py:1.9

Steve Alexander steve@cat-box.net
Wed, 19 Feb 2003 10:36:11 -0500


Update of /cvs-repository/Zope3/src/zope/publisher/interfaces
In directory cvs.zope.org:/tmp/cvs-serv27088/src/zope/publisher/interfaces

Modified Files:
	__init__.py 
Log Message:
finished interfaces for the rest of the interfaces in this module.


=== Zope3/src/zope/publisher/interfaces/__init__.py 1.8 => 1.9 ===
--- Zope3/src/zope/publisher/interfaces/__init__.py:1.8	Wed Feb 19 10:25:58 2003
+++ Zope3/src/zope/publisher/interfaces/__init__.py	Wed Feb 19 10:36:11 2003
@@ -63,8 +63,15 @@
             ob = 'unprintable object'
         return 'Object: %s, name: %s' % (ob, `self.name`)
 
+class IDebugError(ITraversalException):
+    def getObject():
+        'Returns the object being traversed.'
+
+    def getMessage():
+        'Returns the debug message.'
 
 class DebugError(TraversalException):
+    __implements__ = IDebugError
 
     def __init__(self, ob, message):
         self.ob = ob
@@ -79,18 +86,28 @@
     def __str__(self):
         return self.message
 
+class IBadRequest(IPublishingException):
+    def __str__():
+        'Returns the error message.'
 
 class BadRequest(PublishingException):
 
+    __implements__ = IBadRequest
+
     def __init__(self, message):
         self.message = message
 
     def __str__(self):
         return self.message
 
+class IRedirect(IPublishingException):
+    def getLocation():
+        'Returns the location.'
 
 class Redirect(PublishingException):
 
+    __implements__ = IRedirect
+
     def __init__(self, location):
         self.location = location
 
@@ -100,10 +117,15 @@
     def __str__(self):
         return 'Location: %s' % self.location
 
+class IRetry(IPublishingException):
+    def getOriginalException():
+        'Returns the original exception object.'
 
 class Retry(PublishingException):
     """Raise this to retry a request.
     """
+
+    __implements__ = IRetry
 
     def __init__(self, orig_exc=None):
         self.orig_exc = orig_exc