Print out <MIME-BODY> instances in more intelligible form.
authorChris Hanson <org/chris-hanson/cph>
Fri, 2 Jun 2000 02:41:26 +0000 (02:41 +0000)
committerChris Hanson <org/chris-hanson/cph>
Fri, 2 Jun 2000 02:41:26 +0000 (02:41 +0000)
v7/src/imail/imail-core.scm

index 48be09e204424825901bff0d0f144527fefb1b04..43c595930ebf33ad0662bd3718fee0ca6546002f 100644 (file)
@@ -1,6 +1,6 @@
 ;;; -*-Scheme-*-
 ;;;
-;;; $Id: imail-core.scm,v 1.93 2000/06/01 18:46:44 cph Exp $
+;;; $Id: imail-core.scm,v 1.94 2000/06/02 02:41:26 cph Exp $
 ;;;
 ;;; Copyright (c) 1999-2000 Massachusetts Institute of Technology
 ;;;
 (define-generic mime-body-type (body))
 (define-generic mime-body-subtype (body))
 
+(define-method write-instance ((body <mime-body>) port)
+  (write-instance-helper 'MIME-BODY body port 
+    (lambda ()
+      (write-char #\space port)
+      (write (mime-body-type body) port)
+      (write-char #\/ port)
+      (write (mime-body-subtype body) port))))
+
 (define-class <mime-body-one-part> (<mime-body>)
   (id define accessor)
   (description define accessor)
   (parts define accessor))
 
 (define-method mime-body-type ((body <mime-body-multipart>)) body 'MULTIPART)
-
+\f
 (define-class (<mime-envelope>
               (constructor (date subject from sender reply-to to cc bcc
                                  in-reply-to message-id)))