change methods to java type