Implement WebSocket module for Android. Fixes #2837

Summary: The JavaScript code for Android is same as the iOS counterpart, I just added few new lines and used arrow functions instead of binding `this`.
Closes https://github.com/facebook/react-native/pull/2839

Reviewed By: @​svcscm, @vjeux

Differential Revision: D2498703

Pulled By: @mkonicek

fb-gh-sync-id: 3fe958dd5af0efba00df07515f8e33b5d87eb05b
This commit is contained in:
Satyajit Sahoo
2015-10-07 08:28:34 -07:00
committed by facebook-github-bot-8
parent 57a7387d85
commit f4857a6d42
10 changed files with 335 additions and 177 deletions

View File

@@ -21,6 +21,7 @@ import com.facebook.react.modules.fresco.FrescoModule;
import com.facebook.react.modules.network.NetworkingModule;
import com.facebook.react.modules.storage.AsyncStorageModule;
import com.facebook.react.modules.toast.ToastModule;
import com.facebook.react.modules.websocket.WebSocketModule;
import com.facebook.react.uimanager.ViewManager;
import com.facebook.react.views.drawer.ReactDrawerLayoutManager;
import com.facebook.react.views.image.ReactImageManager;
@@ -47,6 +48,7 @@ public class MainReactPackage implements ReactPackage {
new AsyncStorageModule(reactContext),
new FrescoModule(reactContext),
new NetworkingModule(reactContext),
new WebSocketModule(reactContext),
new ToastModule(reactContext));
}