开发者

Android - Client Server App

开发者 https://www.devze.com 2023-04-06 03:32 出处:网络
I have developed Client Server App. My Server is a jetty based webserver that I can query from my PC\'s browser after redirecting a port 开发者_如何转开发to emulator(if my server is on emulator &

I have developed Client Server App. My Server is a jetty based webserver that I can query from my PC's browser after redirecting a port 开发者_如何转开发to emulator(if my server is on emulator & I'm testing it on emulator) or to device(If my server is on my android device I'm testing it on device). My client is a simple app that does HTTP request.

Do I need to forward any port from Android device server so that my Android device client can access that server and query it?

Thanks.


As far as I know, you can query a server running on emulator (or device for that matter) by referring it as localhost and whatever port you started it on, if your server is not local to client then you can directly call using the server's IP, your question is not very clear.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号