Class KotlinReflectionUtils
java.lang.Object
io.fluxzero.common.reflection.KotlinReflectionUtils
Provides utilities for bridging Java reflection with Kotlin reflection.
This class enables Fluxzero internals to interact with Kotlin symbols at runtime, such as retrieving
KFunction or KParameter instances from Java Methods,
Constructors, and Parameters.
It is used primarily to support nullability introspection and Kotlin-specific constructs in reflection-based logic.
Note: This utility is internal and should not be considered part of the public API.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic kotlin.reflect.KFunction<?> asKotlinFunction(Executable executable) static kotlin.reflect.KParameterasKotlinParameter(Parameter parameter) static Class<?> convertIfKotlinClass(Object classObject) static StringgetKotlinParameterName(Parameter parameter) Returns the Kotlin source parameter name for a Java reflection parameter.static Constructor<?> getPrimaryConstructor(Class<?> type) Returns the Java reflection constructor that corresponds to a Kotlin class' primary constructor.
-
Constructor Details
-
KotlinReflectionUtils
public KotlinReflectionUtils()
-
-
Method Details
-
asKotlinParameter
-
getKotlinParameterName
-
getPrimaryConstructor
Returns the Java reflection constructor that corresponds to a Kotlin class' primary constructor.- Parameters:
type- the Kotlin type to inspect- Returns:
- the Java constructor for the Kotlin primary constructor, or
nullwhen none is available
-
asKotlinFunction
-
convertIfKotlinClass
-