socket client 簡易封裝:AndroidSocketClient
socket client 簡易封裝
導入
Add it in your project's build.gradle at the end of repositories:
repositories { // ... maven { url "https://jitpack.io" } }
Step 2. Add the dependency in the form
dependencies { compile 'com.github.vilyever:AndroidSocketClient:1.0.1' }
用法
VDSocketClient socketClient = new VDSocketClient(); socketClient.registerDelegate(new VDSocketClient.VDSocketClientDelegate() { @Override public void didConnectFromSocketClient(VDSocketClient client) { } @Override public void didDisconnectFromSocketClient(VDSocketClient client) { } @Override public void didReceiveResponseFromSocketClient(VDSocketClient client, String response) { } }); socketClient.connect("192.168.1.1", 80);
本文由用戶 jopen 自行上傳分享,僅供網友學習交流。所有權歸原作者,若您的權利被侵害,請聯系管理員。
轉載本站原創文章,請注明出處,并保留原始鏈接、圖片水印。
本站是一個以用戶分享為主的開源技術平臺,歡迎各類分享!