Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Asynchronous socket I/O on Android

Is there a decent mechanism for doing asynchronous I/O using sockets on Android?

I'm aware of the existence of nio channels, but they don't work for me because I need to be able to use MulticastSockets and BluetoothSockets, neither of which support channels.

I'm aware the answer is probably that there isn't one, but as this is a fairly big piece of work I thought I'd ask first to be sure. And if anyone knows of a decent third-party library I might be able to use...

like image 832
David Given Avatar asked Oct 22 '10 16:10

David Given


1 Answers

Other than nio I don't know any built-in option for this problem however there is an interesting answered question on this already on SO.

Take a look at it maybe the third party libraries will help you. Asynchronous IO in Java?

I can't tell how well those libraries work on Android you might also have to get them Android-ready in order to work correctly.

like image 160
Octavian A. Damiean Avatar answered Sep 21 '22 23:09

Octavian A. Damiean