Mobile-XDK-RazerMS_Android_Studio
Mobile-XDK-RazerMS_Android_Studio copied to clipboard
Improving developer exp using SDK
The current API to create a HashMap<String, Object> and manually adding each key and value pair. This method is simple but creates few issues in consuming the API.
- Current method does not easily communicate the expected value. The Value placed can be anything, it maybe a
String,Boolean, or even aString[]. - This easily creates confusion and add in wrong values which may crash the SDK since the SDK does not perform type checking.
- To apply the correct values, developers would have to go thru docs that are not mobile specific. Even so, the values may not have example or easily discovered.
- Certain variable negates another variable effect or only takes effect when a specific variable is set. e.g.
mp_editing_enabled=trueandmp_bill_name_edit_disabled=true
Thanks for the effort and time, we will consider to include this in our next major release.
Its your choice of including it. When i created it i assumed it as a drop-in from the Example code. Devs may choose to use the current method or use Builders. The Builders does add some method count (64k limit), thats why i add it in the example