Does anyone have a recommended tool for generating null-safe (such as one that uses lateinit or requiresNotNull) builders for kotlin classes? I’d normally use named arguments and default params, but I need a builder to support interop with Java.
r
Ryan
05/23/2020, 5:31 PM
there used to be a code->gernerate option
s
Sam Garfinkel
05/23/2020, 5:33 PM
That feature I think is only available for Java code.
c
cristiangm
05/23/2020, 7:49 PM
@JvmOverloads isn't enough?
s
Sam Garfinkel
05/23/2020, 10:58 PM
Not for this use case. I need a real builder.
c
cristiangm
05/24/2020, 8:59 AM
There are some annotation processors to generate builders for Java. A colleague wrote one, but I never used any of them.