Jython Essentials: Rapid Scripting in Java

Overview

Jython is an implementation of the Python programming language written in 100% pure Java, so it runs under any compliant Java Virtual Machine. The secret to Jython's popularity lies in the combination of Java's libraries and tools with Python's rapid development capabilities. With Jython, you can write Python programs that integrate seamlessly with any Java code. And like Python, Jython can be used interactively, so you can get immediate results as you are programming.

Jython ...

See more details below
Paperback (2002)
$31.46
BN.com price
(Save 10%)$34.99 List Price
Other sellers (Paperback)
  • All (20) from $1.99   
  • New (8) from $10.80   
  • Used (12) from $1.99   
Jython Essentials

Available on NOOK devices and apps  
  • NOOK Devices
  • NOOK HD/HD+ Tablet
  • NOOK
  • NOOK Color
  • NOOK Tablet
  • Tablet/Phone
  • NOOK for Windows 8 Tablet
  • NOOK for iOS
  • NOOK for Android
  • NOOK Kids for iPad
  • PC/Mac
  • NOOK for Windows 8
  • NOOK for PC
  • NOOK for Mac
  • NOOK Study
  • NOOK for Web

Want a NOOK? Explore Now

NOOK Book (eBook)
$15.49
BN.com price
(Save 44%)$27.99 List Price

Overview

Jython is an implementation of the Python programming language written in 100% pure Java, so it runs under any compliant Java Virtual Machine. The secret to Jython's popularity lies in the combination of Java's libraries and tools with Python's rapid development capabilities. With Jython, you can write Python programs that integrate seamlessly with any Java code. And like Python, Jython can be used interactively, so you can get immediate results as you are programming.

Jython Essentials provides a solid introduction to the Python language, offering a brief but thorough tour of the Python concepts you'll need to understand to use Jython effectively. The book makes frequent comparisons between Python and Java, with special emphasis on the different object-oriented semantics of the two languages, so Java programmers can quickly get up to speed with Jython.

Jython Essentials also covers the various ways in which Jython and Java can interact. For example, Jython code can create instances of pre-existing Java classes and call methods in those instances. You can write Jython classes that are direct subclasses of existing Java classes and use introspection to discern the capabilities of JavaBeans components. This book provides examples of using Jython with existing Java libraries, including the Swing GUI toolkit, the JDBC database API, the Servlet API, and various XML tools. And finally, the book shows how
Jython can be used as a scripting language within a Java program.

With Jython Essentials, you have everything you need to start creating applications that mix the best of Python's interactivity and Java's robust libraries.

"Jython Essentials" provides a solid introduction to the language, with valuable reference material and examples. Pedroni and Rappin show programmers Jython's advantages in writing tests, playing with Java libraries, and adding scripting to applications. The book has been reviewed by the people behind the language.

Read More Show Less

Editorial Reviews

From Barnes & Noble
The Barnes & Noble Review
What if you could leverage Java's wide reach and powerful enterprise-quality tools for GUI, database, and XML development -- while writing up to 50 percent less code and gaining the productivity and simplicity of scripting? That's what Jython promises and Jython Essentials delivers.

Jython is a complete Python implementation written in 100 percent pure Java and seamlessly integrated with the Java platform. While occasionally a bit slow, it lets Python go just about anywhere Java can go -- into client-side applets that run in browser JVMs; into servlets that run on Java servlet or J2EE servers; into .jar files that can be deployed to multiple platforms. It also gives developers a simple and powerful tool for extending their Java programs and accomplishing tasks that require just too much overhead in Java.

Jython Essentials begins by comparing Python types, structures, and object-oriented features with the nearest Java equivalents; showing how to combine Python statements into functions; explaining how to create reusable Python modules; and introducing good Python programming style. Next, the authors demonstrate the diverse ways Java and Jython can work together. Jython's goal is to make those interactions as transparent as possible; still, there's much to learn.

Coverage includes using existing Java objects and classes from within Jython; automatic type conversions between Java and Python types; creating Jython classes that are direct subclasses of existing Java classes; and introspection shortcuts that evade Java's getSomething and setSomething methods. You'll learn how to use Jython with key Java libraries such as Swing and JDBC; with key Python system, file, and serialization modules, and with Python's PyUnit unit testing framework. The authors conclude by showing how to use Jython as a scripting language within a Java program (very handy for preference/properties files); and how to compile Jython code for distribution.

Jython is a terrific tool, and this book introduces it extremely well. (Bill Camarda)

Bill Camarda is a consultant, writer, and web/multimedia content developer with nearly 20 years' experience in helping technology companies deploy and market advanced software, computing, and networking products and services. His 15 books include Special Edition Using Word 2000 and Upgrading & Fixing Networks For Dummies®, Second Edition.

Read More Show Less

Product Details

  • ISBN-13: 9780596002473
  • Publisher: O'Reilly Media, Incorporated
  • Publication date: 3/28/2002
  • Edition description: 2002
  • Edition number: 1
  • Pages: 302
  • Sales rank: 713,798
  • Product dimensions: 5.90 (w) x 8.80 (h) x 0.70 (d)

Meet the Author

Samuele Pedroni is one of the main Jython developers. He holds a CS flavored diploma in mathematics from the ETH Zurich (Swiss institute of technology in Zurich). He is now a teacher and research assistant at the Institute of Theoretical CS. He plans to come to the US for a PhD in the field of dynamic languages and dynamic compilation. He came to Jython with the interest in improving it with respect to Java importing and reloading. He has developed several important patches related to java integration, classloaders, and the reworking of java/python importing rules and design.

Noel Rappin has a Ph.D. in computer science from the Georgia Institute of Technology, where his research included methods for teaching Object-Oriented Programming and Design. He has extensive production experience in both Java and Python. Noel also contributed an introductory chapter to the book Squeak: Open Personal Computing and Multimedia (PH).

Read More Show Less

Table of Contents

  • Foreword
  • Preface
  • Chapter 1: Introduction to Jython
  • Chapter 2: Jython Basics
  • Chapter 3: Jython Control Flow
  • Chapter 4: Modules and Functions
  • Chapter 5: Object-Oriented Jython
  • Chapter 6: Using Java from Jython
  • Chapter 7: Inheriting from Java
  • Chapter 8: Reflection and JavaBeans
  • Chapter 9: Using Swing
  • Chapter 10: Using Java Libraries
  • Chapter 11: Jython Standard Library
  • Chapter 12: Embedding Jython Inside Java
  • Chapter 13: Compiling Jython
  • Installing Jython
  • Jython Options and Registry
  • Jython Exceptions
  • Jython and CPython Differences
  • Java-to-Python Quick Reference
  • Colophon

Read More Show Less

Customer Reviews

Be the first to write a review
( 0 )
Rating Distribution

5 Star

(0)

4 Star

(0)

3 Star

(0)

2 Star

(0)

1 Star

(0)

Your Rating:

Your Name: Create a Pen Name or

Barnes & Noble.com Review Rules

Our reader reviews allow you to share your comments on titles you liked, or didn't, with others. By submitting an online review, you are representing to Barnes & Noble.com that all information contained in your review is original and accurate in all respects, and that the submission of such content by you and the posting of such content by Barnes & Noble.com does not and will not violate the rights of any third party. Please follow the rules below to help ensure that your review can be posted.

Reviews by Our Customers Under the Age of 13

We highly value and respect everyone's opinion concerning the titles we offer. However, we cannot allow persons under the age of 13 to have accounts at BN.com or to post customer reviews. Please see our Terms of Use for more details.

What to exclude from your review:

Please do not write about reviews, commentary, or information posted on the product page. If you see any errors in the information on the product page, please send us an email.

Reviews should not contain any of the following:

  • - HTML tags, profanity, obscenities, vulgarities, or comments that defame anyone
  • - Time-sensitive information such as tour dates, signings, lectures, etc.
  • - Single-word reviews. Other people will read your review to discover why you liked or didn't like the title. Be descriptive.
  • - Comments focusing on the author or that may ruin the ending for others
  • - Phone numbers, addresses, URLs
  • - Pricing and availability information or alternative ordering information
  • - Advertisements or commercial solicitation

Reminder:

  • - By submitting a review, you grant to Barnes & Noble.com and its sublicensees the royalty-free, perpetual, irrevocable right and license to use the review in accordance with the Barnes & Noble.com Terms of Use.
  • - Barnes & Noble.com reserves the right not to post any review -- particularly those that do not follow the terms and conditions of these Rules. Barnes & Noble.com also reserves the right to remove any review at any time without notice.
  • - See Terms of Use for other conditions and disclaimers.
Search for Products You'd Like to Recommend

Recommend other products that relate to your review. Just search for them below and share!

Create a Pen Name

Your Pen Name is your unique identity on BN.com. It will appear on the reviews you write and other website activities. Your Pen Name cannot be edited, changed or deleted once submitted.

 
Your Pen Name can be any combination of alphanumeric characters (plus - and _), and must be at least two characters long.

Continue Anonymously
Sort by: Showing 1 Customer Reviews
  • Anonymous

    Posted August 3, 2011

    No text was provided for this review.

Sort by: Showing 1 Customer Reviews

If you find inappropriate content, please report it to Barnes & Noble
Why is this product inappropriate?
Comments (optional)