data class KotlinTarget : Target
Generate .kt sources.
KotlinTarget(includes: List<String> = listOf("*"), excludes: List<String> = listOf(), exclusive: Boolean = true, outDirectory: String, android: Boolean = false, javaInterop: Boolean = false, emitDeclaredOptions: Boolean = true, emitAppliedOptions: Boolean = false, emitKotlinSerialization: Boolean = false, rpcCallStyle: RpcCallStyle = RpcCallStyle.SUSPENDING, rpcRole: RpcRole = RpcRole.CLIENT, singleMethodServices: Boolean = false, boxOneOfsMinSize: Int = 5_000, grpcServerCompatible: Boolean = false)
Generate |
val android: Boolean
True for emitted types to implement |
|
val boxOneOfsMinSize: Int
If a oneof has more than or boxOneOfsMinSize fields, it will be generated using boxed oneofs as defined in OneOf. |
|
val emitAppliedOptions: Boolean
True to emit annotations for options applied on messages, fields, etc. |
|
val emitDeclaredOptions: Boolean
True to emit types for options declared on messages, fields, etc. |
|
val emitKotlinSerialization: Boolean
True to emit annotations for kotlinx.serialization. |
|
val excludes: List<String>
Proto types to excluded generated sources for. Types listed here will not be generated for this target. |
|
val exclusive: Boolean
True if types emitted for this target should not also be emitted for other targets. Use this to cause multiple outputs to be emitted for the same input type. |
|
val grpcServerCompatible: Boolean
True to also generate gRPC server-compatible classes. |
|
val includes: List<String>
Proto types to include generated sources for. Types listed here will be generated for this target and not for subsequent targets in the task. |
|
val javaInterop: Boolean
True for emitted types to implement APIs for easier migration from the Java target. |
|
val outDirectory: String |
|
val rpcCallStyle: RpcCallStyle
Blocking or suspending. |
|
val rpcRole: RpcRole
Client or server. |
|
val singleMethodServices: Boolean
True for emitted services to implement one interface per RPC. |