Jason
11/04/2024, 9:46 PM@Target(AnnotationTarget.PROPERTY, AnnotationTarget.CLASS, AnnotationTarget.TYPE, // ADD THIS AnnotationTarget.PARAMETER)
//@Retention(AnnotationRetention.RUNTIME) // Runtime is the default retention, also see KT-41082
public annotation class Serializable(
val with: KClass<out KSerializer<*>> = KSerializer::class // Default value indicates that auto-generated serializer is used
)
EX.
// THIS PRODUCES AN ERROR.
This annotation is not applicable to target 'value parameter'
@Serializable
data class Vehicle(
@Serializable(with = ISODateWithOffsetSerializer::class),
var productionDate: LocalDate? = null,
...
glureau
11/05/2024, 8:01 AMJason
11/05/2024, 9:40 PM@Serializable
annotation, which causes an error, once removed it all works as expected now. thanks for your help