finished UDPAdapter.java