kotlinpoet Questions
2
I'm new using kotlinpoet and I've been reading the documentation and it seems like a great library, but I could not find an example to solve my problem.
I have a dependency lib-domain-0.1.jar in w...
Borough asked 19/12, 2018 at 17:32
2
Using KotlinPoet, in order to generate a PropertySpec for adding properties to classes and constructors, you need a TypeName object.
The TypeMirror.asTypeName() KotlinPoet function is deprecated, b...
Metchnikoff asked 13/4, 2021 at 16:15
2
Solved
Is there any way to omit the redundant public modifier from types and properties generated via
KotlinPoet's TypeSpec.Builder and PropertySpec.Builder respectively?
Fransis asked 19/11, 2020 at 15:18
1
Anyone help me to understand how can I generate protobuf in Kotlin?
I heard about gRPC, wire, KotlinPoet, but I don't understand what are the differences, which one should I use any samples, any si...
Alienee asked 16/6, 2020 at 21:41
4
Solved
In Kotlin, when declaring getting a KClass for a type, such as String::class (which represents values whose type will be String), is there a syntax to indicate that the value is nullable (ie repres...
Upbringing asked 18/5, 2017 at 16:12
1
I want to build an annotation processor that generates a public "non-mutable class" getter function of a private "mutable class" field (e.g. returning a LiveData version of a MutableLiveData field)...
Tawanda asked 16/12, 2018 at 20:21
1
Solved
I want to generate simple data class with KotlinPoet:
data class User(val id: Int)
I do it like that:
val builder = KotlinFile.builder("", "Foo")
val classBuilder = TypeSpec.classBuilder("User"...
Boehmenism asked 11/6, 2017 at 12:25
1
© 2022 - 2024 — McMap. All rights reserved.