Use tern.js with Java code