Files
rr3-apk/decompiled-community/sources/kotlin/jvm/internal/CallableReference.java
Daniel Elliott c080f0d97f Add Discord community version (64-bit only)
- Added realracing3-community.apk (71.57 MB)
- Removed 32-bit support (armeabi-v7a)
- Only includes arm64-v8a libraries
- Decompiled source code included
- Added README-community.md with analysis
2026-02-18 15:48:36 -08:00

147 lines
3.9 KiB
Java

package kotlin.jvm.internal;
import java.io.ObjectStreamException;
import java.io.Serializable;
import java.lang.annotation.Annotation;
import java.util.List;
import java.util.Map;
import kotlin.jvm.KotlinReflectionNotSupportedError;
import kotlin.reflect.KCallable;
import kotlin.reflect.KDeclarationContainer;
import kotlin.reflect.KType;
import kotlin.reflect.KTypeParameter;
import kotlin.reflect.KVisibility;
/* loaded from: classes5.dex */
public abstract class CallableReference implements KCallable, Serializable {
public static final Object NO_RECEIVER = NoReceiver.INSTANCE;
private final boolean isTopLevel;
private final String name;
private final Class owner;
protected final Object receiver;
private transient KCallable reflected;
private final String signature;
public abstract KCallable computeReflected();
public Object getBoundReceiver() {
return this.receiver;
}
public String getName() {
return this.name;
}
public String getSignature() {
return this.signature;
}
public static class NoReceiver implements Serializable {
private static final NoReceiver INSTANCE = new NoReceiver();
private Object readResolve() throws ObjectStreamException {
return INSTANCE;
}
private NoReceiver() {
}
}
public CallableReference() {
this(NO_RECEIVER);
}
public CallableReference(Object obj) {
this(obj, null, null, null, false);
}
public CallableReference(Object obj, Class cls, String str, String str2, boolean z) {
this.receiver = obj;
this.owner = cls;
this.name = str;
this.signature = str2;
this.isTopLevel = z;
}
public KCallable compute() {
KCallable kCallable = this.reflected;
if (kCallable != null) {
return kCallable;
}
KCallable computeReflected = computeReflected();
this.reflected = computeReflected;
return computeReflected;
}
public KCallable getReflected() {
KCallable compute = compute();
if (compute != this) {
return compute;
}
throw new KotlinReflectionNotSupportedError();
}
public KDeclarationContainer getOwner() {
Class cls = this.owner;
if (cls == null) {
return null;
}
return this.isTopLevel ? Reflection.getOrCreateKotlinPackage(cls) : Reflection.getOrCreateKotlinClass(cls);
}
@Override // kotlin.reflect.KCallable
public List<Object> getParameters() {
return getReflected().getParameters();
}
@Override // kotlin.reflect.KCallable
public KType getReturnType() {
return getReflected().getReturnType();
}
@Override // kotlin.reflect.KAnnotatedElement
public List<Annotation> getAnnotations() {
return getReflected().getAnnotations();
}
@Override // kotlin.reflect.KCallable
public List<KTypeParameter> getTypeParameters() {
return getReflected().getTypeParameters();
}
@Override // kotlin.reflect.KCallable
public Object call(Object... objArr) {
return getReflected().call(objArr);
}
@Override // kotlin.reflect.KCallable
public Object callBy(Map map) {
return getReflected().callBy(map);
}
@Override // kotlin.reflect.KCallable
public KVisibility getVisibility() {
return getReflected().getVisibility();
}
@Override // kotlin.reflect.KCallable
public boolean isFinal() {
return getReflected().isFinal();
}
@Override // kotlin.reflect.KCallable
public boolean isOpen() {
return getReflected().isOpen();
}
@Override // kotlin.reflect.KCallable
public boolean isAbstract() {
return getReflected().isAbstract();
}
@Override // kotlin.reflect.KCallable
public boolean isSuspend() {
return getReflected().isSuspend();
}
}