- server side code --> Java (my PC)
- client side code ---> Android/Java
- Using Router Wireless Network
so my questions-
- do I use public (external) OR internal IP?
- UDP or TCP?
- which Port to use, ESTABLISHED or LISTENING?
- Also if I don't want to hardcode size allocation for the image to be received at the server end (and I shouldn't) - whats is the robust alternative to allocating image size to this hard-coded code ?
int filesize=6022386;
byte [] mybytearray = new byte [filesize]; ^
5. and I don't even know, - is this default in bits or bytes? because the average size I would be sending (for this test run) is 500kb. So 500,000 bytes or 500,000,000 bits?
Thanks