Vampire
02/11/2024, 11:27 PMpublic annotation class XmlBefore(vararg val value: String)
so I use
@XmlBefore("display-name"),
but I get
java.lang.ClassCastException: java.lang.String cannot be cast to [Ljava.lang.String;
😞
Any way to mitigate this?
Especially with Kotlin 1.7.10 which I'm pinned to due to Gradle version.
Actually, the error comes from the static initializer of the generated serializer where this annotation is used.
And when giving two arguments it does not even compile.Ruckus
02/12/2024, 12:55 AMVampire
02/12/2024, 12:57 AMRuckus
02/12/2024, 12:58 AMRob Elliot
02/12/2024, 12:08 PM@XmlBefore(arrayOf(“display-name”))
Vampire
02/12/2024, 12:09 PM@XmlBefore(["display-name"])
as I assume arrayOf
is problematic due to needing fixed values for annotation properties. And with that it complained that I need to give String
, not Array<String>
Vampire
02/12/2024, 12:10 PMVampire
02/12/2024, 12:10 PM