com.facebook.flipper.android.AndroidFlipperClient Java Examples
The following examples show how to use
com.facebook.flipper.android.AndroidFlipperClient.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: FlutterFlipperkitPlugin.java From flutter_flipperkit with MIT License | 6 votes |
private void setupChannel(BinaryMessenger messenger, Context context) { this.context = context; SoLoader.init(context.getApplicationContext(), false); if (BuildConfig.DEBUG && FlipperUtils.shouldEnableFlipper(context)) { flipperClient = AndroidFlipperClient.getInstance(context); networkFlipperPlugin = new NetworkFlipperPlugin(); sharedPreferencesFlipperPlugin = new SharedPreferencesFlipperPlugin(context, "FlutterSharedPreferences"); flipperDatabaseBrowserPlugin = new FlipperDatabaseBrowserPlugin(); flipperReduxInspectorPlugin = new FlipperReduxInspectorPlugin(); } this.channel = new MethodChannel(messenger, CHANNEL_NAME); this.channel.setMethodCallHandler(this); this.eventChannel = new EventChannel(messenger, EVENT_CHANNEL_NAME); this.eventChannel.setStreamHandler(this); }
Example #2
Source File: LithoSampleApplication.java From litho with Apache License 2.0 | 6 votes |
@Override public void onCreate() { super.onCreate(); Fresco.initialize(this); SoLoader.init(this, false); if (FlipperUtils.shouldEnableFlipper(this)) { final FlipperClient client = AndroidFlipperClient.getInstance(this); final DescriptorMapping descriptorMapping = DescriptorMapping.withDefaults(); LithoFlipperDescriptors.add(descriptorMapping); client.addPlugin(new InspectorFlipperPlugin(this, descriptorMapping)); client.addPlugin(new SectionsFlipperPlugin(true)); client.start(); } }
Example #3
Source File: FlipperManager.java From zephyr with MIT License | 6 votes |
public FlipperManager(@NonNull Context context) { SoLoader.init(context, false); final FlipperClient flipperClient = AndroidFlipperClient.getInstance(context); final DescriptorMapping descriptorMapping = DescriptorMapping.withDefaults(); final NetworkFlipperPlugin networkPlugin = new NetworkFlipperPlugin(); mOkHttpInterceptor = new FlipperOkhttpInterceptor(networkPlugin, true); flipperClient.addPlugin(new InspectorFlipperPlugin(context, descriptorMapping)); flipperClient.addPlugin(networkPlugin); flipperClient.addPlugin(new SharedPreferencesFlipperPlugin(context)); flipperClient.addPlugin(CrashReporterPlugin.getInstance()); flipperClient.addPlugin(new DatabasesFlipperPlugin(context)); flipperClient.addPlugin(NavigationFlipperPlugin.getInstance()); flipperClient.start(); mIsInitialized = true; }