ietf-822
[Top] [All Lists]

Re: Idle curiosity -- Time to implement MIME

1993-09-07 18:06:50
How much effort (man months?) did it take to implement a MIME parser?

It is hard for me to say for sure -- I implemented my MIME parser very early
and then updated it to track changes in the specification. In addition, my
parser supports nested encodings (but decodes all of them in a single pass).
This complicates things quite a bit, but this was part of the specification
when I wrote the code and I never bothered to tear it all out.

When you knock off all the tracking activity I figure it took about 1.5 weeks.
(I wrote the decoder during the Atlanta IETF in the evening. The rest took
about a week of additional work.)

The parser must produce a data structure within which the body parts
are attached.  Must be able to produce a new instance of the message
(or any body part) from the data structure.

Sure, my code does all this and lots more stuff as well, like on-the-fly
downgrading from 8bit MIME to 7bit MIME.

There must be no policy decisions in the parser on the order of presenting
the body parts; that is decided by other code.

This is actually a problem in my case. The problem isn't the data structure,
which is reasonably straightforward, but the language used to specify
processing order, alternative selection, etc. I've yet to come up with a decent
grammar that let's people tell the code what they want. (Recall that I build
gateways, not user agents.)

Don't include RichText implementation ..

I'm not.

                                Ned

P.S. I should also mention that I code my email software in a mixture of Pascal
and C. Pascal's lexical scoping was what made the single-pass nested decoder
not only doable but rather elegant. It would be a really nasty bit of code in C
and would have taken far longer to write and debug.