Jython Essentials
暫譯: Jython 基礎精要

Samuele Pedroni, Noel Rappin

  • 出版商: O'Reilly
  • 出版日期: 2002-04-30
  • 售價: $1,430
  • 貴賓價: 9.5$1,359
  • 語言: 英文
  • 頁數: 304
  • 裝訂: Paperback
  • ISBN: 0596002475
  • ISBN-13: 9780596002473
  • 已過版

買這商品的人也買了...

商品描述

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.

Table of Contents

Foreword

Preface

1. Introduction to Jython

2. Jython Basics

3. Jython Control Flow

4. Modules and Functions

5. Object-Oriented Jython

6. Using Java from Jython

7. Inheriting from Java

8. Reflection and JavaBeans

9. Using Swing

10. Using Java Libraries

11. Jython Standard Library

12. Embedding Jython Inside Java

13. Compiling Jython

A. Installing Jython

B. Jython Options and Registry

C. Jython Exceptions

D. Jython and CPython Differences

E. Java-to-Python Quick Reference

Index

商品描述(中文翻譯)

Jython 是一個用 100% 純 Java 寫成的 Python 程式語言實作,因此它可以在任何符合規範的 Java 虛擬機上運行。Jython 受歡迎的秘密在於 Java 的函式庫和工具與 Python 的快速開發能力的結合。使用 Jython,您可以編寫與任何 Java 代碼無縫整合的 Python 程式。而且像 Python 一樣,Jython 也可以互動式使用,因此您在編程時可以立即獲得結果。

《Jython Essentials》提供了對 Python 語言的堅實介紹,簡要而徹底地介紹了您需要理解的 Python 概念,以有效使用 Jython。本書經常將 Python 與 Java 進行比較,特別強調這兩種語言不同的物件導向語義,以便 Java 程式設計師能快速掌握 Jython。

《Jython Essentials》還涵蓋了 Jython 和 Java 之間互動的各種方式。例如,Jython 代碼可以創建現有 Java 類的實例並調用這些實例中的方法。您可以編寫 Jython 類,這些類是現有 Java 類的直接子類,並使用反射來辨識 JavaBeans 組件的能力。本書提供了使用 Jython 與現有 Java 函式庫的範例,包括 Swing GUI 工具包、JDBC 數據庫 API、Servlet API 和各種 XML 工具。最後,本書展示了如何在 Java 程式中將 Jython 作為腳本語言使用。

有了《Jython Essentials》,您擁有開始創建結合 Python 互動性和 Java 強大函式庫的應用程式所需的一切。

目錄
前言
序言

1. Jython 介紹
2. Jython 基礎
3. Jython 控制流程
4. 模組與函式
5. 物件導向 Jython
6. 從 Jython 使用 Java
7. 繼承自 Java
8. 反射與 JavaBeans
9. 使用 Swing
10. 使用 Java 函式庫
11. Jython 標準函式庫
12. 在 Java 中嵌入 Jython
13. 編譯 Jython
A. 安裝 Jython
B. Jython 選項與登錄
C. Jython 異常
D. Jython 與 CPython 的差異
E. Java 到 Python 快速參考
索引