From: morioka Date: Fri, 19 Jun 1998 23:10:39 +0000 (+0000) Subject: Move `mime-message-structure' from mime-parse.el to mime-def.el. X-Git-Tag: flim-1_5_0~29 X-Git-Url: http://git.chise.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9c0db3733d6fe2a23a85a05144e946e4af127e85;p=elisp%2Fflim.git Move `mime-message-structure' from mime-parse.el to mime-def.el. --- diff --git a/mime-def.el b/mime-def.el index 15f66e4..0babafb 100644 --- a/mime-def.el +++ b/mime-def.el @@ -146,6 +146,14 @@ (cdr (assoc parameter (mime-content-type-parameters content-type)))) +(defsubst mime-type/subtype-string (type &optional subtype) + "Return type/subtype string from TYPE and SUBTYPE." + (if type + (if subtype + (format "%s/%s" type subtype) + (format "%s" type)))) + + ;;; @ Content-Disposition ;;; @@ -166,7 +174,7 @@ (mime-content-disposition-parameter content-disposition "filename")) -;;; @ MIME-entity +;;; @ MIME entity ;;; (defsubst make-mime-entity (buffer @@ -214,15 +222,31 @@ (mime-entity-media-subtype entity-info))) -;;; @ utility +;;; @ message structure ;;; -(defsubst mime-type/subtype-string (type &optional subtype) - "Return type/subtype string from TYPE and SUBTYPE." - (if type - (if subtype - (format "%s/%s" type subtype) - (format "%s" type)))) +(defvar mime-message-structure nil + "Information about structure of message. +Please use reference function `mime-entity-SLOT' to get value of SLOT. + +Following is a list of slots of the structure: + +buffer buffer includes this entity (buffer). +node-id node-id (list of integers) +header-start minimum point of header in raw-buffer +header-end maximum point of header in raw-buffer +body-start minimum point of body in raw-buffer +body-end maximum point of body in raw-buffer +content-type content-type (content-type) +content-disposition content-disposition (content-disposition) +encoding Content-Transfer-Encoding (string or nil) +children entities included in this entity (list of entity) + +If an entity includes other entities in its body, such as multipart or +message/rfc822, `mime-entity' structures of them are included in +`children', so the `mime-entity' structure become a tree.") + +(make-variable-buffer-local 'mime-message-structure) ;;; @ end diff --git a/mime-parse.el b/mime-parse.el index b50ce1a..38b7f00 100644 --- a/mime-parse.el +++ b/mime-parse.el @@ -270,28 +270,6 @@ mime-{parse|read}-Content-Type." ;;; @ for buffer ;;; -(defvar mime-message-structure nil - "Information about structure of message. -Please use reference function `mime-entity-SLOT' to get value of SLOT. - -Following is a list of slots of the structure: - -buffer buffer includes this entity (buffer). -node-id node-id (list of integers) -header-start minimum point of header in raw-buffer -header-end maximum point of header in raw-buffer -body-start minimum point of body in raw-buffer -body-end maximum point of body in raw-buffer -content-type content-type (content-type) -content-disposition content-disposition (content-disposition) -encoding Content-Transfer-Encoding (string or nil) -children entities included in this entity (list of entity) - -If an entity includes other entities in its body, such as multipart or -message/rfc822, `mime-entity' structures of them are included in -`children', so the `mime-entity' structure become a tree.") -(make-variable-buffer-local 'mime-message-structure) - ;;;###autoload (defun mime-parse-buffer (&optional buffer) "Parse BUFFER as a MIME message.