KormaMutableApi
annotation class KormaMutableApi
Mutable APIs follow the following convention:
interface IType { val ... }
class MType : IType(override var ...) : IType
Content copied to clipboard
Then in usage places:
fun doSomethingWith(a: IType, out: MType = MType()): MType
Content copied to clipboard
This convention supports allocation-free APIs by being able to preallocate instances and passing them as the output.