[ENH] Scamper content type handling

John Duncan jddst19+ at pitt.edu
Wed Nov 3 04:29:04 UTC 1999


Yeah, Lex, you're on the right track.  Personally, I'm not that
worried about Scamper yet, since I expect it to be very much different
very soon.  If anyone is interested, here's my take on the situation:

> > > 'text/html; charset=iso-8859-1'
                  ^^^^^^^^^^^^^^^^^^

is an example of some sort of annotation, perhaps introduced in a more
recent version of MIME or HTTP.  What I expect is that the header
processor in HTTPSocket currently treats this line as always an 'x/x'
string, though I can imagine many other things going in there:
'text/html; charset=iso-8859-1; language=en-us' etc. So, if I'm right,
then MimeDocument should keep a dictionary or list of annotations and
HTTPSocket has to be changed to use it. That's more than one fix, and
Scamper currently isn't very smart, so it's good enough to just filter
out the rest of it in the content string. Plus, it'll fit into the
640k of memory we set aside for applications. :)

-John

> -----Original Message-----
> From: Lex Spoon [mailto:lex at cc.gatech.edu]
> Sent: Tuesday, November 02, 1999 11:34 AM
> To: squeak at cs.uiuc.edu
> Subject: Re: [ENH] Scamper content type handling
>
>
> I think there is a contentType method in HTTPSocket which is
> what is used when the  MimeDocument is created.  Put your
> fix in there,
> and it would affect everything that uses MimeDocuments.
>
> If that doesn't work, peek into getDocument:etc and postDocument:etc
> methods on the class side of HTTPSocket and see how where
> the documents content-type comes form.  Fix them to use the
> contentType method :)
>
> Lex
>
>
> >
> > One note: This is in the quick-fix category. If there is
> a standard
> > method of dealing with annotations, it should be in the
> MimeDocument
> > class, not Scamper. I just don't have the time to muck around with
> > this stuff yet.
> >
> > -John
> >
> > > -----Original Message-----
> > > From: John Duncan [mailto:jddst19+ at pitt.edu]
> > > Sent: Tuesday, November 02, 1999 9:59 AM
> > > To: Squeak
> > > Subject: [ENH] Scamper content type handling
> > >
> > >
> > >
> > > Some locations, notably the W3C, return content types like this:
> > >
> > > 	'text/html; charset=iso-8859-1'
> > >
> > > This used to confuse Scamper [2.6], who, after this cs, now
> > > looks for
> > > the 'text/html' substring. Eventually, I'm sure, we'll
> make use of
> > > charset annotations for the multilingual stuff.
> > >
> > > -John
> > >
> > > --
> > > "In any event, once Robert Craft forged the
> > > Stravinsky-Schoenberg axis
> > > in the 1950s and the eclecticism of the 1960s
> alleviated the austere
> > > serialism of the previous decade, the futures market in
> Hindemithian
> > > repose was struck by panic selling."
> > >                                   -Glenn Gould
> > >
> > >
> >
> >
>
>





More information about the Squeak-dev mailing list