apkfuckery/com.discord/smali/com/esotericsoftware/kryo/Registration.smali

205 lines
5.3 KiB
Smali
Raw Normal View History

2019-07-24 11:27:29 +00:00
.class public Lcom/esotericsoftware/kryo/Registration;
.super Ljava/lang/Object;
.source "Registration.java"
# instance fields
2019-12-06 03:29:40 +00:00
.field public final id:I
2019-07-24 11:27:29 +00:00
2019-12-21 01:41:59 +00:00
.field public instantiator:Lz/c/b/a;
2019-07-24 11:27:29 +00:00
2019-12-06 03:29:40 +00:00
.field public serializer:Lcom/esotericsoftware/kryo/Serializer;
2019-07-24 11:27:29 +00:00
2019-12-06 03:29:40 +00:00
.field public final type:Ljava/lang/Class;
2019-07-24 11:27:29 +00:00
# direct methods
.method public constructor <init>(Ljava/lang/Class;Lcom/esotericsoftware/kryo/Serializer;I)V
.locals 0
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
if-eqz p1, :cond_1
if-eqz p2, :cond_0
iput-object p1, p0, Lcom/esotericsoftware/kryo/Registration;->type:Ljava/lang/Class;
iput-object p2, p0, Lcom/esotericsoftware/kryo/Registration;->serializer:Lcom/esotericsoftware/kryo/Serializer;
iput p3, p0, Lcom/esotericsoftware/kryo/Registration;->id:I
return-void
:cond_0
new-instance p1, Ljava/lang/IllegalArgumentException;
const-string p2, "serializer cannot be null."
invoke-direct {p1, p2}, Ljava/lang/IllegalArgumentException;-><init>(Ljava/lang/String;)V
throw p1
:cond_1
new-instance p1, Ljava/lang/IllegalArgumentException;
const-string p2, "type cannot be null."
invoke-direct {p1, p2}, Ljava/lang/IllegalArgumentException;-><init>(Ljava/lang/String;)V
throw p1
.end method
# virtual methods
.method public getId()I
.locals 1
iget v0, p0, Lcom/esotericsoftware/kryo/Registration;->id:I
return v0
.end method
2019-12-21 01:41:59 +00:00
.method public getInstantiator()Lz/c/b/a;
2019-07-24 11:27:29 +00:00
.locals 1
2019-12-21 01:41:59 +00:00
iget-object v0, p0, Lcom/esotericsoftware/kryo/Registration;->instantiator:Lz/c/b/a;
2019-07-24 11:27:29 +00:00
return-object v0
.end method
.method public getSerializer()Lcom/esotericsoftware/kryo/Serializer;
.locals 1
iget-object v0, p0, Lcom/esotericsoftware/kryo/Registration;->serializer:Lcom/esotericsoftware/kryo/Serializer;
return-object v0
.end method
.method public getType()Ljava/lang/Class;
.locals 1
iget-object v0, p0, Lcom/esotericsoftware/kryo/Registration;->type:Ljava/lang/Class;
return-object v0
.end method
2019-12-21 01:41:59 +00:00
.method public setInstantiator(Lz/c/b/a;)V
2019-07-24 11:27:29 +00:00
.locals 1
if-eqz p1, :cond_0
2019-12-21 01:41:59 +00:00
iput-object p1, p0, Lcom/esotericsoftware/kryo/Registration;->instantiator:Lz/c/b/a;
2019-07-24 11:27:29 +00:00
return-void
:cond_0
new-instance p1, Ljava/lang/IllegalArgumentException;
const-string v0, "instantiator cannot be null."
invoke-direct {p1, v0}, Ljava/lang/IllegalArgumentException;-><init>(Ljava/lang/String;)V
throw p1
.end method
.method public setSerializer(Lcom/esotericsoftware/kryo/Serializer;)V
.locals 2
if-eqz p1, :cond_1
iput-object p1, p0, Lcom/esotericsoftware/kryo/Registration;->serializer:Lcom/esotericsoftware/kryo/Serializer;
2019-12-06 03:29:40 +00:00
sget-boolean v0, Le/i/a/a;->d:Z
2019-07-24 11:27:29 +00:00
if-eqz v0, :cond_0
2019-12-06 03:29:40 +00:00
const-string v0, "Update registered serializer: "
2019-07-24 11:27:29 +00:00
2019-12-06 03:29:40 +00:00
invoke-static {v0}, Le/e/b/a/a;->a(Ljava/lang/String;)Ljava/lang/StringBuilder;
2019-07-24 11:27:29 +00:00
2019-12-06 03:29:40 +00:00
move-result-object v0
2019-07-24 11:27:29 +00:00
iget-object v1, p0, Lcom/esotericsoftware/kryo/Registration;->type:Ljava/lang/Class;
invoke-virtual {v1}, Ljava/lang/Class;->getName()Ljava/lang/String;
move-result-object v1
invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
const-string v1, " ("
invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
invoke-virtual {p1}, Ljava/lang/Object;->getClass()Ljava/lang/Class;
move-result-object p1
invoke-virtual {p1}, Ljava/lang/Class;->getName()Ljava/lang/String;
move-result-object p1
invoke-virtual {v0, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
const-string p1, ")"
invoke-virtual {v0, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
move-result-object p1
const-string v0, "kryo"
2019-12-06 03:29:40 +00:00
invoke-static {v0, p1}, Le/i/a/a;->b(Ljava/lang/String;Ljava/lang/String;)V
2019-07-24 11:27:29 +00:00
:cond_0
return-void
:cond_1
new-instance p1, Ljava/lang/IllegalArgumentException;
const-string v0, "serializer cannot be null."
invoke-direct {p1, v0}, Ljava/lang/IllegalArgumentException;-><init>(Ljava/lang/String;)V
throw p1
.end method
.method public toString()Ljava/lang/String;
.locals 2
2019-12-06 03:29:40 +00:00
const-string v0, "["
2019-07-24 11:27:29 +00:00
2019-12-06 03:29:40 +00:00
invoke-static {v0}, Le/e/b/a/a;->a(Ljava/lang/String;)Ljava/lang/StringBuilder;
2019-07-24 11:27:29 +00:00
2019-12-06 03:29:40 +00:00
move-result-object v0
2019-07-24 11:27:29 +00:00
iget v1, p0, Lcom/esotericsoftware/kryo/Registration;->id:I
invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;
const-string v1, ", "
invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
iget-object v1, p0, Lcom/esotericsoftware/kryo/Registration;->type:Ljava/lang/Class;
invoke-static {v1}, Lcom/esotericsoftware/kryo/util/Util;->className(Ljava/lang/Class;)Ljava/lang/String;
move-result-object v1
invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
const-string v1, "]"
invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
move-result-object v0
return-object v0
.end method