MapDefaultValue

@Target(allowedTargets = [AnnotationTarget.PROPERTY])
annotation class MapDefaultValue(val expression: String)

Deprecated (with error)

Removed in 2.0: there is no @MapDefaultValue — declare a constructor default on the target field (val plan: String = "FREE"); mapping omits the argument so the Kotlin default applies. Use @IgnoreDefaultValue when a default must NOT act as a wire fallback.

1.x expression-based fallback — removed without an annotation replacement: the Kotlin constructor default IS the fallback in 2.0. Declare val plan: String = "FREE" on the target; mapping omits the argument so the default applies (and IgnoreDefaultValue opts a default out of being a wire fallback).

Properties

Link copied to clipboard