-
Chapter 1 Getting Started
-
Introduction
-
Installing JRuby
-
Managing Packages with RubyGems
-
Using Both Ruby and JRuby
-
Sharing RubyGems
-
Referencing Java Classes from Ruby
-
Converting a Ruby Array into a Java Array
-
Adding JAR Files to the Classpath
-
Extending a Java Class in Ruby
-
Implementing a Java Interface in Ruby
-
Opening Java Classes with JRuby
-
Setting Up Eclipse for JRuby Development
-
Setting Up NetBeans for JRuby Development
-
Platform Detection in a JRuby Application
-
-
Chapter 2 JRuby on Rails
-
Introduction
-
Installing and Setting Up Rails
-
Packaging Rails As a Java EE Web Application
-
Using an External Gem Repository with a Web Application
-
Configuring the JRuby-Rack Servlet
-
Packaging Rails with a JNDI DataSource
-
Deploying Rails on Tomcat
-
Deploying Rails on JBoss
-
Deploying Rails on Jetty
-
Deploying Rails with jetty_rails
-
Deploying Rails with Mongrel
-
Deploying Rails on the GlassFish v2 Server
-
Using the GlassFish v3 Gem
-
Using ActiveRecord Outside of Rails
-
Accessing Common Java Servlet Information
-
Configuring Session Storage
-
Controlling the Classes, Directories, and Other Files Packaged into a Rails WAR File
-
Changing the Name of the WAR File and the Staging Area
-
Deploying a Rails Application to the Root Context
-
Creating a Rails Application with Aptana Studio
-
Accessing Static Files in Your Rails Java EE Application
-
-
Chapter 3 Java Integration
-
Introduction
-
Executing Ruby from Java
-
Invoking JRuby Through the Bean Scripting Framework
-
Invoking JRuby Through Java Scripting Support
-
Logging from Ruby with Jakarta Commons Logging
-
Using the Java Concurrency Utilities
-
Creating JavaBean Style Accessor Methods
-
Writing Consistent Code
-
Transforming XML with TrAX
-
Creating a Pool of JRuby Runtimes
-
Performing Remote Management with JMX
-
Accessing Native Libraries with JRuby
-
-
Chapter 4 Enterprise Java
-
Introduction
-
Creating a JNDI Context
-
Sending JMS Messages
-
Receiving JMS Messages
-
Implementing an Enterprise JavaBean with JRuby
-
Defining Spring Beans in JRuby
-
Creating Refreshable JRuby Spring Beans
-
Defining JRuby Spring Beans Inline
-
Applying Spring-Aware Interfaces to JRuby Objects
-
Creating Spring MVC Controllers with JRuby
-
Using Hibernate with JRuby
-
Using the Java Persistence API with JRuby
-
Making SOAP Calls
-
Simplifying LDAP Access
-
-
Chapter 5 User Interface and Graphics
-
Introduction
-
Creating Swing Applications
-
Swing Event Handling
-
Long-Running Tasks in Swing Applications
-
Packaging Standalone Applications
-
Packaging JRuby Web Start Applications
-
Creating JRuby Applets
-
Manipulating Images
-
Creating SWT Applications
-
Accessing the Native Desktop
-
Accessing the System Tray
-
Swing Development with JRuby Domain-Specific Languages
-
Using the Monkeybars Framework for Swing Development
-
Creating Qt Applications with JRuby
-
-
Chapter 6 Build Tools
-
Introduction
-
Adding Ruby Scripting to Ant Builds
-
Using Ruby in Ant Conditions
-
Writing an Ant Task in Ruby
-
Adding Ruby Scripting to Maven Builds
-
Writing a Maven Plugin with JRuby
-
Building Java Projects with Raven
-
Referencing Libraries with Raven
-
Hosting a Private Raven Repository
-
Running JUnit Tests with Raven
-
Building Java Projects with Buildr
-
Referencing Libraries with Buildr
-
Building with Rake Inside Hudson
-
Adding Ruby Script to a Hudson Job
-
-
Chapter 7 Testing
-
Introduction
-
Unit Testing Java Code with Test/Unit
-
Unit Testing Java Code with dust
-
Unit Testing Java Code with Expectations
-
Testing Java Code with RSpec
-
Creating Mock Objects with Mocha
-
Modifying the JtestR Classpath
-
Grouping Tests for JtestR
-
Using the JtestR Command-Line Options
-
Running JtestR with Ant
-
Running JtestR with Maven
-
Improving JtestR Performance
-
-
Chapter 8 The JRuby Community
-
Introduction
-
Building JRuby from Source
-
Submitting an Issue Report for JRuby
-
Using the JRuby Mailing Lists
-
-
Colophon
- Title:
- JRuby Cookbook
- By:
- Justin Edelson, Henry Liu
- Publisher:
- O'Reilly Media
- Formats:
-
- Ebook
- Safari Books Online
- Print Release:
- November 2008
- Ebook Release:
- November 2008
- Pages:
- 224
- Print ISBN:
- 978-0-596-51980-3
- | ISBN 10:
- 0-596-51980-X
- Ebook ISBN:
- 978-0-596-15647-3
- | ISBN 10:
- 0-596-15647-2
The animal on the cover of JRuby Cookbook is an African civet (Civettictis civetta). Unlike the other members of the Viverridae family, which resemble cats, the African civet is a dog-like animal with large hindquarters and a low-head stance. Its coat is gray with black stripes and spots, and it has a gray face, a white snout, and dark markings around its eyes like a raccoon. Along its back runs a short mane of stiff hairs that stand on end when the civet is alarmed. From head to tail, an African civet is about 4 feet long, and it weighs 30 to 40 pounds.
The African civet ranges across sub-Saharan Africa in forests and savannas. Solitary and nocturnal, it hides in caves or tree hollows during the day. It eats anything edible, including insects, plants, and carrion, and it preys on small animals such as hares and moongooses. Like all civets, the African civet has glands that produce a scented fluid, which it uses to mark its territory. This musk, known as civetone or simply civet, is one of the oldest known ingredients in perfumes. Although it is still used in the perfume industry today, the trade for civet musk has been on the decline since synthetic musk was introduced in the mid-1900s.
The cover image is from Richard Lydekker's Royal Natural History. The cover font is Adobe ITC Garamond. The text font is Linotype Birka; the heading font is Adobe Myriad Condensed; and the code font is LucasFont's TheSansMonoCondensed.
