kotlinx.rpc.codegen.extension.ServiceDeclaration.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of kotlinx-rpc-compiler-plugin-backend Show documentation
Show all versions of kotlinx-rpc-compiler-plugin-backend Show documentation
kotlinx.rpc, a Kotlin library for adding asynchronous RPC services to your applications.
/*
* Copyright 2023-2024 JetBrains s.r.o and contributors. Use of this source code is governed by the Apache 2.0 license.
*/
package kotlinx.rpc.codegen.extension
import org.jetbrains.kotlin.ir.declarations.IrClass
import org.jetbrains.kotlin.ir.declarations.IrProperty
import org.jetbrains.kotlin.ir.declarations.IrSimpleFunction
import org.jetbrains.kotlin.ir.declarations.IrValueParameter
import org.jetbrains.kotlin.ir.types.IrType
import org.jetbrains.kotlin.ir.util.defaultType
class ServiceDeclaration(
val service: IrClass,
val stubClass: IrClass,
val methods: List,
val fields: List,
) {
val simpleName: String = service.name.asString()
val serviceType = service.defaultType
class Method(
val function: IrSimpleFunction,
val arguments: List,
) {
class Argument(
val value: IrValueParameter,
val type: IrType,
)
}
class FlowField(
val property: IrProperty,
val flowKind: Kind,
) {
enum class Kind {
Plain, Shared, State;
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy