Socket for UDP and TCP with Java