Code example for DatagramSocket

Methods: close, isClosed

0
	// =========================================================== 
	// Methods 
	// =========================================================== 
 
	public static void closeSocket(final DatagramSocket pDatagramSocket) {
		if(pDatagramSocket != null && !pDatagramSocket.isClosed()) {
			pDatagramSocket.close();
		} 
	} 
 
	public static void closeSocket(final Socket pSocket) {
		if(pSocket != null && !pSocket.isClosed()) {
			try { 
				pSocket.close();
			} catch (final IOException e) {
				Debug.e(e);
			} 
		} 
	} 
 
	public static void closeSocket(final ServerSocket pServerSocket) {