@Test
public void testJavaClass2() throws Exception {

   ScriptEngineManager mgr = new ScriptEngineManager();
   ScriptEngine engine = mgr.getEngineByExtension("java");
   Invocable inv = (Invocable) engine.eval( //
         "import java.util.List;\r\n" + //
               "import org.unidal.helper.Splitters;\r\n" + //
               "public class A2 {\t\n" + //
               "public List<String> split(String source) { return Splitters.by('.').split(source); }\r\n" + //
               "}\r\n");
   Assert.assertEquals("[a, b, c, d, e]", inv.invokeFunction("split", "a.b.c.d.e").toString());
}