Merge branch '6.1.x'
This commit is contained in:
commit
92f4e883b3
|
|
@ -28,9 +28,11 @@ import kotlin.reflect.KClass;
|
|||
import kotlin.reflect.KClassifier;
|
||||
import kotlin.reflect.KFunction;
|
||||
import kotlin.reflect.KParameter;
|
||||
import kotlin.reflect.KType;
|
||||
import kotlin.reflect.full.KCallables;
|
||||
import kotlin.reflect.full.KClasses;
|
||||
import kotlin.reflect.jvm.KCallablesJvm;
|
||||
import kotlin.reflect.jvm.KTypesJvm;
|
||||
import kotlin.reflect.jvm.ReflectJvmMapping;
|
||||
import kotlinx.coroutines.BuildersKt;
|
||||
import kotlinx.coroutines.CoroutineStart;
|
||||
|
|
@ -117,19 +119,14 @@ public abstract class CoroutinesUtils {
|
|||
case VALUE, EXTENSION_RECEIVER -> {
|
||||
Object arg = args[index];
|
||||
if (!(parameter.isOptional() && arg == null)) {
|
||||
if (parameter.getType().getClassifier() instanceof KClass<?> kClass) {
|
||||
Class<?> javaClass = JvmClassMappingKt.getJavaClass(kClass);
|
||||
if (KotlinDetector.isInlineClass(javaClass)
|
||||
&& !(parameter.getType().isMarkedNullable() && arg == null)) {
|
||||
argMap.put(parameter, KClasses.getPrimaryConstructor(kClass).call(arg));
|
||||
}
|
||||
else {
|
||||
argMap.put(parameter, arg);
|
||||
KType type = parameter.getType();
|
||||
if (!(type.isMarkedNullable() && arg == null)) {
|
||||
KClass<?> kClass = KTypesJvm.getJvmErasure(type);
|
||||
if (KotlinDetector.isInlineClass(JvmClassMappingKt.getJavaClass(kClass))) {
|
||||
arg = KClasses.getPrimaryConstructor(kClass).call(arg);
|
||||
}
|
||||
}
|
||||
else {
|
||||
argMap.put(parameter, arg);
|
||||
}
|
||||
argMap.put(parameter, arg);
|
||||
}
|
||||
index++;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -26,8 +26,10 @@ import kotlin.jvm.JvmClassMappingKt;
|
|||
import kotlin.reflect.KClass;
|
||||
import kotlin.reflect.KFunction;
|
||||
import kotlin.reflect.KParameter;
|
||||
import kotlin.reflect.KType;
|
||||
import kotlin.reflect.full.KClasses;
|
||||
import kotlin.reflect.jvm.KCallablesJvm;
|
||||
import kotlin.reflect.jvm.KTypesJvm;
|
||||
import kotlin.reflect.jvm.ReflectJvmMapping;
|
||||
|
||||
import org.springframework.context.MessageSource;
|
||||
|
|
@ -315,19 +317,14 @@ public class InvocableHandlerMethod extends HandlerMethod {
|
|||
case VALUE, EXTENSION_RECEIVER -> {
|
||||
Object arg = args[index];
|
||||
if (!(parameter.isOptional() && arg == null)) {
|
||||
if (parameter.getType().getClassifier() instanceof KClass<?> kClass) {
|
||||
Class<?> javaClass = JvmClassMappingKt.getJavaClass(kClass);
|
||||
if (KotlinDetector.isInlineClass(javaClass)
|
||||
&& !(parameter.getType().isMarkedNullable() && arg == null)) {
|
||||
argMap.put(parameter, KClasses.getPrimaryConstructor(kClass).call(arg));
|
||||
}
|
||||
else {
|
||||
argMap.put(parameter, arg);
|
||||
KType type = parameter.getType();
|
||||
if (!(type.isMarkedNullable() && arg == null)) {
|
||||
KClass<?> kClass = KTypesJvm.getJvmErasure(type);
|
||||
if (KotlinDetector.isInlineClass(JvmClassMappingKt.getJavaClass(kClass))) {
|
||||
arg = KClasses.getPrimaryConstructor(kClass).call(arg);
|
||||
}
|
||||
}
|
||||
else {
|
||||
argMap.put(parameter, arg);
|
||||
}
|
||||
argMap.put(parameter, arg);
|
||||
}
|
||||
index++;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -31,8 +31,10 @@ import kotlin.jvm.JvmClassMappingKt;
|
|||
import kotlin.reflect.KClass;
|
||||
import kotlin.reflect.KFunction;
|
||||
import kotlin.reflect.KParameter;
|
||||
import kotlin.reflect.KType;
|
||||
import kotlin.reflect.full.KClasses;
|
||||
import kotlin.reflect.jvm.KCallablesJvm;
|
||||
import kotlin.reflect.jvm.KTypesJvm;
|
||||
import kotlin.reflect.jvm.ReflectJvmMapping;
|
||||
import reactor.core.publisher.Mono;
|
||||
|
||||
|
|
@ -326,19 +328,14 @@ public class InvocableHandlerMethod extends HandlerMethod {
|
|||
case VALUE, EXTENSION_RECEIVER -> {
|
||||
Object arg = args[index];
|
||||
if (!(parameter.isOptional() && arg == null)) {
|
||||
if (parameter.getType().getClassifier() instanceof KClass<?> kClass) {
|
||||
Class<?> javaClass = JvmClassMappingKt.getJavaClass(kClass);
|
||||
if (KotlinDetector.isInlineClass(javaClass)
|
||||
&& !(parameter.getType().isMarkedNullable() && arg == null)) {
|
||||
argMap.put(parameter, KClasses.getPrimaryConstructor(kClass).call(arg));
|
||||
}
|
||||
else {
|
||||
argMap.put(parameter, arg);
|
||||
KType type = parameter.getType();
|
||||
if (!(type.isMarkedNullable() && arg == null)) {
|
||||
KClass<?> kClass = KTypesJvm.getJvmErasure(type);
|
||||
if (KotlinDetector.isInlineClass(JvmClassMappingKt.getJavaClass(kClass))) {
|
||||
arg = KClasses.getPrimaryConstructor(kClass).call(arg);
|
||||
}
|
||||
}
|
||||
else {
|
||||
argMap.put(parameter, arg);
|
||||
}
|
||||
argMap.put(parameter, arg);
|
||||
}
|
||||
index++;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue