> My feeling is that a delimited string might not be appropriate for this
> because content-disposition has an internal grammar, unlike comments,
> ids, and descriptions.
>
> Perhaps something like what mhbuild does with Content-Description in
> plaintext is appropriate, i.e. if a Content-Disposition line follows
> immediately after a directive it is treated as a header for that MIME
> entity. In fact, what might be even clearer is if the Content-Disposition
> line is escaped with a #, because then if it's divorced from a directive
> mhbuild will treat it as an error. In fact, this might be a way to
> do all MIME extension fields. The grammar then becomes
> 
>             directive    ::=     "#" type "/" subtype
>                                      0*(";" attribute "=" value)
>                                      [ "(" comment ")" ]
>                                      [ "<" id ">" ]
>                                      [ "[" description "]" ]
>                                      [ filename ]
>                                      EOL
>                                      [ "#" extension-field ]
> 
> where extension-field just can't look like a directive.

Like this?

          extension-field    ::=    "Content-" fieldname ":"
                                        attribute [ "=" value ]
                                        0*(";" attribute [ "=" value ])

#application/pdf; <>[ Adobe Portable Document Format (PDF) v1.2 ] /tmp/foo.pdf
#Content-Disposition: attachment; filename="foo.pdf"

David


_______________________________________________
Nmh-workers mailing list
[email protected]
http://lists.nongnu.org/mailman/listinfo/nmh-workers

Reply via email to