Browser remote interface from Javascript to Java