calling java directly