Java demo