sudhanshu singh
03/11/2018, 12:59 PMdata class SectionMenuModel(@SerializedName("title") val title: String,
@SerializedName("type") val type: MenuTypeModel,
@SerializedName("enabled") val enabled: Boolean)
and MenutypeModel as a sealed class
sealed class MenuTypeModel {
object MAP : MenuTypeModel()
object CALENDAR : MenuTypeModel()
object LEADERBOARD : MenuTypeModel()
}
while parsing this SectionMenuModel response from an api I get the error
Failed to invoke private MenuTypeModel() with no args
I am trying to use menutype model as kind of enum