Shannon Fang wrote: > Although the document mentioned that JRuby enables you to embed a ruby > interpreter into your java application, I have not seen any document or > samples on this. Could any one give me a hint? Preferrably several line of > code to get a look and fee. Hi Shannon, We're a little short on documentation in some areas on JRuby. But it's pretty easy to embed the JRuby interpreter. Something like this (beware, untested): Ruby runtime = org.jruby.Ruby.getDefaultInstance(); runtime.evalScript("puts 1 + 2"); That's about it. You can also pass in a stream of Ruby source instead, to evaluate bigger scripts. The docs on JRuby's Java support should be able to help you with the rest. You may be able to find someone with some more interesting sample code on the jruby-user mailing list. By the way, we would be grateful if someone gave us a good sample application that embeds JRuby to distribute with our sample code. /Anders - your friendly neighborhood JRuby developer -- A n d e r s B e n g t s s o n | ndrsbngtssn / yahoo.se Stockholm, Sweden | _____________________________________________________ Gratis e-mail resten av livet pwww.yahoo.se/mail Busenkelt!