(mmbuffer-parse-multipart): Add new optional argument
authortomo <tomo>
Sat, 9 Dec 2000 04:06:34 +0000 (04:06 +0000)
committertomo <tomo>
Sat, 9 Dec 2000 04:06:34 +0000 (04:06 +0000)
`representation-type'.
(mmbuffer-parse-encapsulated): Likewise.

mmbuffer.el

index 97fc783..6a7803a 100644 (file)
 ;;; @ children
 ;;;
 
-(defun mmbuffer-parse-multipart (entity)
+(defun mmbuffer-parse-multipart (entity &optional representation-type)
   (with-current-buffer (mime-buffer-entity-buffer-internal entity)
-    (let* ((representation-type
-           (mime-entity-representation-type-internal entity))
-          (content-type (mime-entity-content-type-internal entity))
+    (or representation-type
+       (setq representation-type
+             (mime-entity-representation-type-internal entity)))
+    (let* ((content-type (mime-entity-content-type-internal entity))
           (dash-boundary
            (concat "--"
                    (mime-content-type-parameter content-type "boundary")))
          nil)
        ))))
 
-(defun mmbuffer-parse-encapsulated (entity &optional external)
+(defun mmbuffer-parse-encapsulated (entity &optional external
+                                          representation-type)
   (mime-entity-set-children-internal
    entity
    (with-current-buffer (mime-buffer-entity-buffer-internal entity)
                  (progn
                    (require 'mmexternal)
                    'mime-external-entity)
-               (mime-entity-representation-type-internal entity))
+               (or representation-type
+                   (mime-entity-representation-type-internal entity)))
              nil
              entity (cons 0 (mime-entity-node-id-internal entity))))))))