DrawableId
Drawable represented by Android resource ID.
Should be explicitly subclassed to ensure stable persistence, and serialVersionUID
must be present. Example:
object InstallIcon : DrawableId {
private const val serialVersionUID = 3692803605642002954L
override fun drawableId() = R.drawable.ic_install
private fun readResolve(): Any = InstallIcon
}
Content copied to clipboard