can't seem to find a pause or sleep function in the java api...anyone got it?