By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
439,931 Members | 1,976 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 439,931 IT Pros & Developers. It's quick & easy.

Good use for Jython

P: n/a
Other than being used to wrap Java classes, what other real use is
there for Jython being that Python has many other GUI toolkits
available? Also, these toolkits like Tkinter are so much better for
client usage (and faster) than Swing, so what would be the advantage
for using Jython? or Is Jython really just so that Java developers can
write Java code faster?

Mike Wimpe

Jul 18 '05 #1
Share this Question
Share on Google+
6 Replies


P: n/a
Mike Wimpe wrote:
Other than being used to wrap Java classes, what other real use is
there for Jython being that Python has many other GUI toolkits
available? Also, these toolkits like Tkinter are so much better for
client usage (and faster) than Swing, so what would be the advantage
for using Jython?


What ever gave you the impression that Jython was targeted only at
people who wanted to do GUI development?
--
Michael Hoffman
Jul 18 '05 #2

P: n/a
On 15 Mar 2005 23:54:16 -0800, Mike Wimpe <mi*******@yahoo.com> wrote:
Other than being used to wrap Java classes, what other real use is
there for Jython being that Python has many other GUI toolkits
available? Also, these toolkits like Tkinter are so much better for
client usage (and faster) than Swing, so what would be the advantage
for using Jython? or Is Jython really just so that Java developers can
write Java code faster?

Mike Wimpe

--
http://mail.python.org/mailman/listinfo/python-list


I haven't done anything substatial with Jython yet, but I consder it
to be valuable in areas where you have to do something quick and
dirty, perhaps debug an EJB running on an app server for example.

Bean shell serves the same purpose and the syntax is pretty much Java
so the learning curve isn't as steep for java developers.

I see it as a way of getting around some of the requirements of the
language. If I needed to connect to java systems together and I needed
to do it quickly, and the quality of requirements was less than
adequate, I'd rather write a script(beanshell/jython/groovy) than
booting up eclipse and contributing to the interface cesspool .

--
Thomas G. Willis
http://paperbackmusic.net
Jul 18 '05 #3

P: n/a
Mike Wimpe wrote:
Other than being used to wrap Java classes, what other real use is
there for Jython being that Python has many other GUI toolkits
available? Also, these toolkits like Tkinter are so much better for
client usage (and faster) than Swing, so what would be the advantage
for using Jython? or Is Jython really just so that Java developers can
write Java code faster?


I use Jython a lot. I have a background in Java and I am working in a Java shop, but I prefer to
code in Python, so Jython has some appeal:
- Works with existing Java libraries, both in-house proprietary libs and favorite third-party libs.
The third-party libs probably have Python equivalents, but it's nice to be able to keep using some
favorite tools.
- Doesn't add any new requirements to the target machine (just needs the JRE they already have,
Python install not needed) (yes, I know about py2exe)
- No one has to know :-) I can ship a jar file (or several) that contains my program, it looks just
like Java.

A recent poster on jython-users had switched from Python to Jython because he preferred Swing over
the GUI toolkits available with Python so I guess there is room for more than one opinion on that point.

Kent
Jul 18 '05 #4

P: n/a
On 15 Mar 2005 23:54:16 -0800, Mike Wimpe <mi*******@yahoo.com> wrote:
Other than being used to wrap Java classes, what other real use is
there for Jython being that Python has many other GUI toolkits
available? Also, these toolkits like Tkinter are so much better for
client usage (and faster) than Swing, so what would be the advantage
for using Jython? or Is Jython really just so that Java developers can
write Java code faster?

Mike Wimpe

--
http://mail.python.org/mailman/listinfo/python-list


I use an embedded Jython interpreter extensively for the business
logic layer of a Servlet/J2ee application. The back end uses,
Hibernate to connect to the database, so Jython's JavaBean
functionality is very useful for me, vastly simplifying and clarifying
my own logic.

As an added bonus, it is vastly easier to debug and redeploy a Jython
script file into a running system than it is to do the same with a
session EJB.

--
Sean Blakey
Saint of Mild Amusement, Evil Genius, Big Geek
Python/Java/C++/C(Unix/Windows/Palm/Web) developer
quine = ['print "quine =",quine,"; exec(quine[0])"'] ; exec(quine[0])
Jul 18 '05 #5

P: n/a
The only reason i can think of to use it would be for the purpos of using an Applet in a WebPage, as
the Jythonc tool can compile Jython classes to Java byte code.

But if your not in need of an Applet, then youll probably want to go with a normal Python GUI
toolkit like wxPython (or QT or Tkinter....).

Peter

----- Original Message -----
From: "Mike Wimpe" <mi*******@yahoo.com>
Newsgroups: comp.lang.python
To: <py*********@python.org>
Sent: Tuesday, March 15, 2005 11:54 PM
Subject: Good use for Jython

Other than being used to wrap Java classes, what other real use is
there for Jython being that Python has many other GUI toolkits
available? Also, these toolkits like Tkinter are so much better for
client usage (and faster) than Swing, so what would be the advantage
for using Jython? or Is Jython really just so that Java developers can
write Java code faster?

Mike Wimpe

--
http://mail.python.org/mailman/listinfo/python-list


--
No virus found in this incoming message.
Checked by AVG Anti-Virus.
Version: 7.0.308 / Virus Database: 266.7.3 - Release Date: 3/15/2005


--
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.308 / Virus Database: 266.7.3 - Release Date: 3/15/2005

Jul 18 '05 #6

P: n/a
Mike Wimpe <mi*******@yahoo.com> wrote or quoted:
Other than being used to wrap Java classes, what other real use is
there for Jython being that Python has many other GUI toolkits
available? Also, these toolkits like Tkinter are so much better for
client usage (and faster) than Swing, so what would be the advantage
for using Jython? or Is Jython really just so that Java developers can
write Java code faster?


Jython allows Python programmers to access to the large volume of
existing Java code and libraries - and provides access to a ubiquitous
and widely distributed runtime environment.
--
__________
|im |yler http://timtyler.org/ ti*@tt1lock.org Remove lock to reply.
Jul 18 '05 #7

This discussion thread is closed

Replies have been disabled for this discussion.