Java porting draft