[ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
Content-Type 欄 は media-type (media-type) や MIME charset といった entity (@ref{entity}) の内容の種類や表現形式などを記述 するためのもので、RFC 2045 (RFC 2045) で定義されています。
[Memo]
歴史的には RFC 1049 で Content-Type 欄が提案されている。但し、MIME の media-type のような type と subtype の区別はなく、MIME charset のような 文字符号の種類を表現することもできない。
FLIM は Content-Type 欄を構文解析する関数と Content-Type 欄の解析結果を 格納する構造体 mime-content-type を提供します。
4.1 Content-Type 欄の形式 | ||
4.2 mime-content-type 構造体 | ||
4.3 Content-Type 欄の解析器 | ||
4.4 Content-Type に関する有用な関数 |
[ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
Content-Type 欄の形式は以下のように定義されています:
“Content-Type” “:” type “/” subtype *( “;” parameter )
例えば、
Content-Type: image/jpeg
や
Content-Type: text/plain; charset=iso-2022-jp
などのように用いられます。
ここで、‘type’ と ‘subtype’ は entity の形式を示すもので、両者を総称し て、‘media-type’ と呼ぶことにします。上記の例における ‘image/jpeg’ や ‘text/plain’ は media-type の1つです。
[Memo]
Content-Type 欄のない entity は
Content-Type: text/plain; charset=us-asciiとして解釈される。(cf. us-ascii)
[ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
Content-Type 欄の情報を格納するための構造体。
この構造体を参照するには mime-content-type-要素名
という名前の参
照関数を用いる。
この構造体の要素は以下の通りである:
media-type の主型 (symbol).
media-type の副型 (symbol).
Content-Type 欄の parameter (連想 list).
&optional parameters
content-type の生成子。
content-type の parameter の値を返す。
[ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
string を content-type として解析した結果を返す。
現在の buffer の Content-Type 欄を読み取り、解析した結果を返す。
Content-Type 欄が存在しない場合は nil を返す。
[ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
type と subtype から type/subtype 形式の文字列を返す。
[ << ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
This document was generated by Yasutaka SHINDOH on May 11, 2011 using texi2html 1.82.