Brandon Goodin wrote:
David,

I agree. But, it would be nice to be able to access Java Objects from a
scripting language. For example, If someone wanted to use Lucene to index
their site, and the site already exists in php. Then it would be appropriate
to be able to interact with the Lucene java objects and integrate that into
the already existing system.


You can do this very easily from Jython. To show you what it looks like, the following code actually instantiates org.apache.lucene.search.IndexSearcher and a couple other Lucene classes within a Python script:

<http://hkn.eecs.berkeley.edu/~dyoo/jython/test_searching.jy>


Even though in a previous life I spent most of a year working on a large PHP project, my personal opinion is that Python/Jython is a far superior scripting language to PHP, in fact I often see it as a dynamically-typed scripted version of Java. (Yes, I do realize there are fundamental differences in the object models of each language, but there are also many similarities between Java and Python syntax.)



For writing a web-enabled application, my only choice would be Java/J2EE. But Python (and PHP and Perl) are very cool too, especially when you just need to add some basic server-side programming to a simple site, such as a blog or a web calendar. I do not intend to do requirements analysis or UML diagrams when I add a database-driven "book reviews" section to my personal web site.





Erik



--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to