Subj : Re: Equivalent of JS_InitClass for global object? To : netscape.public.mozilla.jseng From : John J Lee Date : Tue Aug 26 2003 11:31 pm On Tue, 26 Aug 2003, Brendan Eich wrote: > John J. Lee wrote: [...] > What DOM code? I'm starting with 4DOM (which is compliant with an old version of level 2 HTML DOM, I just discovered) and some bits of pxdom (because 4DOM deliberately doesn't do 'live' collections), plus various hacks applied by me. The code is currently not pretty, I must confess. I expect I'll discover soon how adequate this is for the task (the task being simply my wanting a package for interpreting embedded JS that's relatively dependency-free and as close to 'pure Python' as possible, not any commercial interest)... > If you are writing your own DOM, what rendering code (if > any) will you use? I won't use any rendering code. This is for web scraping / testing. [...] > >Also, there were build and interoperability issues with PyXPCOM last [...] > See http://pyxpcom.mozdev.org soon (coming online still). Thanks! [...] > >>The advantage of PyConnect is that if you go down the JS/Python route, > >>you're inviting n^2 inter-language-runtime bridge-building. If you > >>instead choose to build only XPCOM/language bridges, you need n for n > >>languages. Plus XPCOM, of course. > >> > >> > > > >Yeah, but I don't care about those other languages ;-P and XPCOM is > >just another thing to learn from my PoV (*how* many COM- / CORBA-like > >component systems on *nix now? 4 or 5, maybe?!). > > > > > > Dunno, but that doesn't alter the fact that you may be heading down a > road where you buy off more work in the long run that you would like, by > choosing to optimize the short term. Oh, sure, I understand that. When I wrote 'just another thing...' I was responding to your 'Plus XPCOM, of course' which, in its context, suggested to me that you were partly selling its advantages as a pleasant environment to work in (but of course, you were also referring to the fact that "all" the Mozilla code is accessible through XPCOM, which is the other great advantage). As I said, though, PyXPCOM is nice, what I've written is a hack. John .