New files.
authormorioka <morioka>
Sun, 28 Jun 1998 19:47:40 +0000 (19:47 +0000)
committermorioka <morioka>
Sun, 28 Jun 1998 19:47:40 +0000 (19:47 +0000)
mmbuffer.el [new file with mode: 0644]
mmcooked.el [new file with mode: 0644]

diff --git a/mmbuffer.el b/mmbuffer.el
new file mode 100644 (file)
index 0000000..fd948b3
--- /dev/null
@@ -0,0 +1,58 @@
+;;; mmbuffer.el --- MIME entity module for binary buffer
+
+;; Copyright (C) 1998 Free Software Foundation, Inc.
+
+;; Author: MORIOKA Tomohiko <morioka@jaist.ac.jp>
+;; Keywords: MIME, multimedia, mail, news
+
+;; This file is part of FLIM (Faithful Library about Internet Message).
+
+;; This program is free software; you can redistribute it and/or
+;; modify it under the terms of the GNU General Public License as
+;; published by the Free Software Foundation; either version 2, or (at
+;; your option) any later version.
+
+;; This program is distributed in the hope that it will be useful, but
+;; WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+;; General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING.  If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
+
+;;; Code:
+
+(require 'mime-parse)
+
+(defun mmbuffer-open-entity (location)
+  (mime-parse-buffer location)
+  )
+
+(defun mmbuffer-entity-point-min (entity)
+  (mime-entity-header-start-internal entity)
+  )
+
+(defun mmbuffer-entity-point-max (entity)
+  (mime-entity-body-end-internal entity)
+  )
+
+(defun mmbuffer-fetch-field (entity field-name)
+  (save-excursion
+    (set-buffer (mime-entity-buffer-internal entity))
+    (save-restriction
+      (narrow-to-region (mime-entity-header-start-internal entity)
+                       (mime-entity-header-end-internal entity))
+      (std11-fetch-field field-name)
+      )))
+
+(defun mmbuffer-cooked-p () nil)
+
+
+;;; @ end
+;;;
+
+(provide 'mmbuffer)
+
+;;; mmbuffer.el ends here
diff --git a/mmcooked.el b/mmcooked.el
new file mode 100644 (file)
index 0000000..8d4e0df
--- /dev/null
@@ -0,0 +1,45 @@
+;;; mmcooked.el --- MIME entity implementation for binary buffer
+
+;; Copyright (C) 1998 Free Software Foundation, Inc.
+
+;; Author: MORIOKA Tomohiko <morioka@jaist.ac.jp>
+;; Keywords: MIME, multimedia, mail, news
+
+;; This file is part of FLIM (Faithful Library about Internet Message).
+
+;; This program is free software; you can redistribute it and/or
+;; modify it under the terms of the GNU General Public License as
+;; published by the Free Software Foundation; either version 2, or (at
+;; your option) any later version.
+
+;; This program is distributed in the hope that it will be useful, but
+;; WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+;; General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING.  If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
+
+;;; Code:
+
+(require 'mmbuffer)
+
+(defun mmcooked-open-entity (location)
+  (mime-parse-buffer location 'cooked)
+  )
+
+(defalias 'mmcooked-entity-point-min   'mmbuffer-entity-point-min)
+(defalias 'mmcooked-entity-point-max   'mmbuffer-entity-point-max)
+(defalias 'mmcooked-fetch-field                'mmbuffer-fetch-field)
+
+(defun mmcooked-cooked-p () t)
+
+
+;;; @ end
+;;;
+
+(provide 'mmcooked)
+
+;;; mmcooked.el ends here