MessageSerializedForm.smali
.class final Lcom/squareup/wire/MessageSerializedForm;
.super Ljava/lang/Object;
.source "MessageSerializedForm.java"
# interfaces
.implements Ljava/io/Serializable;
# annotations
.annotation system Ldalvik/annotation/Signature;
value = {
"<M:",
"Lcom/squareup/wire/Message<",
"TM;TB;>;B:",
"Lcom/squareup/wire/Message$Builder<",
"TM;TB;>;>",
"Ljava/lang/Object;",
"Ljava/io/Serializable;"
}
.end annotation
# static fields
.field private static final serialVersionUID:J
# instance fields
.field private final bytes:[B
.field private final messageClass:Ljava/lang/Class;
.annotation system Ldalvik/annotation/Signature;
value = {
"Ljava/lang/Class<",
"TM;>;"
}
.end annotation
.end field
# direct methods
.method public constructor <init>([BLjava/lang/Class;)V
.registers 3
.annotation system Ldalvik/annotation/Signature;
value = {
"([B",
"Ljava/lang/Class<",
"TM;>;)V"
}
.end annotation
.line 1
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
.line 2
iput-object p1, p0, Lcom/squareup/wire/MessageSerializedForm;->bytes:[B
.line 3
iput-object p2, p0, Lcom/squareup/wire/MessageSerializedForm;->messageClass:Ljava/lang/Class;
return-void
.end method
# virtual methods
.method readResolve()Ljava/lang/Object;
.registers 3
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/io/ObjectStreamException;
}
.end annotation
.line 1
iget-object v0, p0, Lcom/squareup/wire/MessageSerializedForm;->messageClass:Ljava/lang/Class;
invoke-static {v0}, Lcom/squareup/wire/ProtoAdapter;->get(Ljava/lang/Class;)Lcom/squareup/wire/ProtoAdapter;
move-result-object v0
.line 2
:try_start_6
iget-object v1, p0, Lcom/squareup/wire/MessageSerializedForm;->bytes:[B
invoke-virtual {v0, v1}, Lcom/squareup/wire/ProtoAdapter;->decode([B)Ljava/lang/Object;
move-result-object v0
:try_end_c
.catch Ljava/io/IOException; {:try_start_6 .. :try_end_c} :catch_d
return-object v0
:catch_d
move-exception v0
.line 3
new-instance v1, Ljava/io/StreamCorruptedException;
invoke-virtual {v0}, Ljava/io/IOException;->getMessage()Ljava/lang/String;
move-result-object v0
invoke-direct {v1, v0}, Ljava/io/StreamCorruptedException;-><init>(Ljava/lang/String;)V
throw v1
.end method