Files
flipper/android
John Knox fa3dcdc5dd NativePlugins API update
Summary:
The main change is is changing from the inheritance model:
`FlipperPlugin > NativePlugin > TablePlugin > ConcretePlugin`

to a composition model where:
`NativePlugin > TablePlugin > ConcretePlugin`

And behind the scenes, there's a `FlipperPlugin` that has a `NativePlugin` reference.

Now your native plugin will call methods like (in the table case) `display.updateRows` instead of `super.updateRows()`

The reasons for this are:

* Testability: we can easily mock the display and assert output.
* Encapsulation: Previously, native plugins could call `mConnection.send(...)` and send completely unsupported messages to the desktop. Now they only have access to the display's public api, which is guaranteed to work.

I've also changed it so that on every row update, we send the latest table metadata along with it. This makes sure we can ensure that the right table schema is displayed for the current data.

QueryResponder interface also added, which will come in useful for queryable datasets.

Reviewed By: passy

Differential Revision: D14751885

fbshipit-source-id: ea0bbd25f7eaa60020f8866fe210d8bd1c22e90b
2019-04-05 10:06:14 -07:00
..
2019-03-18 07:34:44 -07:00
2019-04-05 10:06:14 -07:00
2019-02-19 09:06:19 -08:00
2019-03-20 09:13:21 -07:00
2018-09-25 04:02:29 -07:00
2018-08-06 14:11:54 -07:00