Note: Beta 1.1 is the same code as Beta 1 - the only difference is the addition of a NOTICE file.
<strong>Features</strong></div>
<ul dir="ltr" style="padding-right: 40px; ">
<li>
Works with both #-style and $-style bindings and for both value bindings and method bindings (e.g. beforePageLoad)</li>
<li>
Allows for Ruby "Script Libraries". For now, these are accomplished by creating a "ruby" folder inside the database's WEB-INF folder (via Package Explorer) and putting Ruby scripts in there. Then, they can be references on a page like a normal library but with "text/ruby" or "text/x-ruby" as the type: <xp:script src="/somelibrary.rb" type="text/ruby" clientSide="false"/></li>
<li>
Can access local variables as readily as in Server JavaScript, such as "session", "database", and repeat-local variables</li>
<li>
The included file "domino.rb" contains some extensions for the Domino product objects in Ruby, allowing for Ruby-style looping in collection classes (e.g. docs.each { |doc| ... }) and hash-style access to a document's item values (e.g. doc["Form"]). It is meant to be added to the project as a "Script Library" as described above</li>
<li>
Though currently commented out, there is some extremely-basic support for arbitrary other scripting languages. If you uncomment the applicable/* */ block in frostillicus/ScriptingViewHandler.java, it will register all available JSR-223-compliant languages with binding names based on the language name provided by the language package (such as "#{Groovy: ... }" or "#{scheme: ... }"). Note that other languages have had essentially no testing, Jython is known to be problematic, and there is no automatic variable resolution. See <a href="http://frostillic.us/f.nsf/posts/F660516EC59A25FC852579E5007D5F9C">http://frostillic.us/f.nsf/posts/F660516EC59A25FC852579E5007D5F9C</a> for a casual overview</li>
</ul>
<strong>Installation</strong></div>
<ul dir="ltr" style="padding-right: 40px; ">
<li>
Install JRuby 1.6+ on the server. The most straightforward way to do this in lieu of an Eclipse Update Site package is to download jruby-complete.jar and place it in the server's jvm/lib/ext folder, then restart HTTP</li>
<li>
I'm not sure if it's necessary, but if you run into security problems, it may be required to grant the JVM additional permissions: <a href="http://www-01.ibm.com/support/docview.wss?uid=swg21279509">http://www-01.ibm.com/support/docview.wss?uid=swg21279509</a></li>
<li>
In the application where you want to use Ruby bindings, copy in the provided Java classes as Java design elements (or otherwise add them to the project's build path)</li>
<li>
Modify the application's faces-config.xml to add frostillicus.ScriptingViewHandler as a view handler (see faces-config-example.xml)</li>
<li>
Start using "#{ruby: ... }" bindings! I suggest starting with something simple, like <xp:text value="#{ruby:Time.now.year}"/> for troubleshooting purposes</li>
</ul>
</div>