package com.fireworksdk.bridge.models import org.json.JSONObject object FWControlsInsetModelDeserializer { private const val TOP = "top" private const val BOTTOM = "bottom" fun deserialize(jsonObject: JSONObject?): FWControlsInsetModel? { jsonObject ?: return null return FWControlsInsetModel( top = jsonObject.optInt(TOP, 0), bottom = jsonObject.optInt(BOTTOM, 0), ) } }