[JDEV] Encoding and dating thoughts

Scott Robinson scott at tranzoa.com
Fri Jul 30 00:48:40 CDT 1999


Here are my thoughts on this.

First off, escaping is evil. If anything, we should have a
<encoding></encoding> packaging method. The default, when no <encoding> tag
has been specified, should be UTF-8. (the XML "forced" standard. ;))

I would point out, to those that have suggested that we should not get into
internationalization, that Jabber is _NOT_ a US only product. Or, if we want
it to be, we're shooting ourselves in the foot.

I would also like to make a suggestion on the date format. In the next
couple of years all UNIX systems will be forced to move to 64 bit (or above)
integers. Why? 2038 == $maxint. The simple solution would be to just blit
the int and RFC ???? timezone. ex. "12341234 PST"

If anyone sees a reason to add something I'm missing, by all means mention
it, but shouldn't this take care of all our problems easily?

Scott.

* Jon A. Cruz translated into ASCII [Thu, Jul 29, 1999 at 09:48:13PM -0700][<37A12E8D.1A4EBF62 at geocities.com>]
> Dave Smith wrote:
> 
> > One more thought...
> >
> > What if we did something along these lines for encoding...
> >
> > <login>
> >         <encoding type="ISO-8859-1">
> >         <user><![CDATA[...]]></user>
> >         <encoding type="UTF8">
> >         <pass>APASSWORD</pass>
> > </login>
> >
> > So, everytime a <encoding> tag is encountered, all CDATA segments following
> > will be properly escaped and setup to contain data in the specified encoding,
> > until another encoding tag is encountered. When the server or client recvs this
> > packet and begins walking the DOM, it can be setup to appropriately handle
> > different encodings -- if it supports them. Otherwise, it can make a
> > "best-guess" about the data, without bothering to check for encoding "hints" and
> > try and read it without decoding?!
> >
> > The only downside to such an approach would be the fact that it requires the
> > packet to be reassembled in the order it was created (although any decent DOM
> > should do this, right?).
> >
> > D.
> 
> Earlier internationalization schemes used various forms of escapes to switch
> encodings/languages. Using escapes tends to bring on a plethora of extra problems.
> Personally, I really think it should be avoided.
> 
> --
> "My new computer's got the clocks, it rocks
> But it was obsolete before I opened the box" - W.A.Y.
> 
> 
> 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 240 bytes
Desc: not available
URL: <https://www.jabber.org/jdev/attachments/19990729/d3255bab/attachment-0002.pgp>


More information about the JDev mailing list