Changed jsni methods to use extern