1979 lines
46 KiB
Smali
1979 lines
46 KiB
Smali
.class public Lcom/google/flatbuffers/FlatBufferBuilder;
|
|
.super Ljava/lang/Object;
|
|
.source "FlatBufferBuilder.java"
|
|
|
|
|
|
# annotations
|
|
.annotation system Ldalvik/annotation/MemberClasses;
|
|
value = {
|
|
Lcom/google/flatbuffers/FlatBufferBuilder$ByteBufferBackedInputStream;,
|
|
Lcom/google/flatbuffers/FlatBufferBuilder$HeapByteBufferFactory;,
|
|
Lcom/google/flatbuffers/FlatBufferBuilder$ByteBufferFactory;
|
|
}
|
|
.end annotation
|
|
|
|
|
|
# static fields
|
|
.field public static final synthetic $assertionsDisabled:Z
|
|
|
|
|
|
# instance fields
|
|
.field public bb:Ljava/nio/ByteBuffer;
|
|
|
|
.field public bb_factory:Lcom/google/flatbuffers/FlatBufferBuilder$ByteBufferFactory;
|
|
|
|
.field public finished:Z
|
|
|
|
.field public force_defaults:Z
|
|
|
|
.field public minalign:I
|
|
|
|
.field public nested:Z
|
|
|
|
.field public num_vtables:I
|
|
|
|
.field public object_start:I
|
|
|
|
.field public space:I
|
|
|
|
.field public final utf8:Lcom/google/flatbuffers/Utf8;
|
|
|
|
.field public vector_num_elems:I
|
|
|
|
.field public vtable:[I
|
|
|
|
.field public vtable_in_use:I
|
|
|
|
.field public vtables:[I
|
|
|
|
|
|
# direct methods
|
|
.method public static constructor <clinit>()V
|
|
.locals 0
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public constructor <init>()V
|
|
.locals 1
|
|
|
|
const/16 v0, 0x400
|
|
|
|
.line 20
|
|
invoke-direct {p0, v0}, Lcom/google/flatbuffers/FlatBufferBuilder;-><init>(I)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public constructor <init>(I)V
|
|
.locals 3
|
|
|
|
.line 19
|
|
sget-object v0, Lcom/google/flatbuffers/FlatBufferBuilder$HeapByteBufferFactory;->INSTANCE:Lcom/google/flatbuffers/FlatBufferBuilder$HeapByteBufferFactory;
|
|
|
|
invoke-static {}, Lcom/google/flatbuffers/Utf8;->getDefault()Lcom/google/flatbuffers/Utf8;
|
|
|
|
move-result-object v1
|
|
|
|
const/4 v2, 0x0
|
|
|
|
invoke-direct {p0, p1, v0, v2, v1}, Lcom/google/flatbuffers/FlatBufferBuilder;-><init>(ILcom/google/flatbuffers/FlatBufferBuilder$ByteBufferFactory;Ljava/nio/ByteBuffer;Lcom/google/flatbuffers/Utf8;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public constructor <init>(ILcom/google/flatbuffers/FlatBufferBuilder$ByteBufferFactory;)V
|
|
.locals 2
|
|
|
|
.line 1
|
|
invoke-static {}, Lcom/google/flatbuffers/Utf8;->getDefault()Lcom/google/flatbuffers/Utf8;
|
|
|
|
move-result-object v0
|
|
|
|
const/4 v1, 0x0
|
|
|
|
invoke-direct {p0, p1, p2, v1, v0}, Lcom/google/flatbuffers/FlatBufferBuilder;-><init>(ILcom/google/flatbuffers/FlatBufferBuilder$ByteBufferFactory;Ljava/nio/ByteBuffer;Lcom/google/flatbuffers/Utf8;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public constructor <init>(ILcom/google/flatbuffers/FlatBufferBuilder$ByteBufferFactory;Ljava/nio/ByteBuffer;Lcom/google/flatbuffers/Utf8;)V
|
|
.locals 3
|
|
|
|
.line 2
|
|
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
|
|
|
|
const/4 v0, 0x1
|
|
|
|
.line 3
|
|
iput v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->minalign:I
|
|
|
|
const/4 v1, 0x0
|
|
|
|
.line 4
|
|
iput-object v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->vtable:[I
|
|
|
|
const/4 v1, 0x0
|
|
|
|
.line 5
|
|
iput v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->vtable_in_use:I
|
|
|
|
.line 6
|
|
iput-boolean v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->nested:Z
|
|
|
|
.line 7
|
|
iput-boolean v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->finished:Z
|
|
|
|
const/16 v2, 0x10
|
|
|
|
new-array v2, v2, [I
|
|
|
|
.line 8
|
|
iput-object v2, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->vtables:[I
|
|
|
|
.line 9
|
|
iput v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->num_vtables:I
|
|
|
|
.line 10
|
|
iput v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->vector_num_elems:I
|
|
|
|
.line 11
|
|
iput-boolean v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->force_defaults:Z
|
|
|
|
if-gtz p1, :cond_0
|
|
|
|
move p1, v0
|
|
|
|
.line 12
|
|
:cond_0
|
|
iput p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
.line 13
|
|
iput-object p2, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb_factory:Lcom/google/flatbuffers/FlatBufferBuilder$ByteBufferFactory;
|
|
|
|
if-eqz p3, :cond_1
|
|
|
|
.line 14
|
|
iput-object p3, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
.line 15
|
|
invoke-virtual {p3}, Ljava/nio/ByteBuffer;->clear()Ljava/nio/Buffer;
|
|
|
|
.line 16
|
|
iget-object p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
sget-object p2, Ljava/nio/ByteOrder;->LITTLE_ENDIAN:Ljava/nio/ByteOrder;
|
|
|
|
invoke-virtual {p1, p2}, Ljava/nio/ByteBuffer;->order(Ljava/nio/ByteOrder;)Ljava/nio/ByteBuffer;
|
|
|
|
goto :goto_0
|
|
|
|
.line 17
|
|
:cond_1
|
|
invoke-virtual {p2, p1}, Lcom/google/flatbuffers/FlatBufferBuilder$ByteBufferFactory;->newByteBuffer(I)Ljava/nio/ByteBuffer;
|
|
|
|
move-result-object p1
|
|
|
|
iput-object p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
.line 18
|
|
:goto_0
|
|
iput-object p4, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->utf8:Lcom/google/flatbuffers/Utf8;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public constructor <init>(Ljava/nio/ByteBuffer;)V
|
|
.locals 1
|
|
|
|
.line 22
|
|
new-instance v0, Lcom/google/flatbuffers/FlatBufferBuilder$HeapByteBufferFactory;
|
|
|
|
invoke-direct {v0}, Lcom/google/flatbuffers/FlatBufferBuilder$HeapByteBufferFactory;-><init>()V
|
|
|
|
invoke-direct {p0, p1, v0}, Lcom/google/flatbuffers/FlatBufferBuilder;-><init>(Ljava/nio/ByteBuffer;Lcom/google/flatbuffers/FlatBufferBuilder$ByteBufferFactory;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public constructor <init>(Ljava/nio/ByteBuffer;Lcom/google/flatbuffers/FlatBufferBuilder$ByteBufferFactory;)V
|
|
.locals 2
|
|
|
|
.line 21
|
|
invoke-virtual {p1}, Ljava/nio/ByteBuffer;->capacity()I
|
|
|
|
move-result v0
|
|
|
|
invoke-static {}, Lcom/google/flatbuffers/Utf8;->getDefault()Lcom/google/flatbuffers/Utf8;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-direct {p0, v0, p2, p1, v1}, Lcom/google/flatbuffers/FlatBufferBuilder;-><init>(ILcom/google/flatbuffers/FlatBufferBuilder$ByteBufferFactory;Ljava/nio/ByteBuffer;Lcom/google/flatbuffers/Utf8;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method private dataStart()I
|
|
.locals 1
|
|
.annotation runtime Ljava/lang/Deprecated;
|
|
.end annotation
|
|
|
|
.line 1
|
|
invoke-virtual {p0}, Lcom/google/flatbuffers/FlatBufferBuilder;->finished()V
|
|
|
|
.line 2
|
|
iget v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
return v0
|
|
.end method
|
|
|
|
.method public static growByteBuffer(Ljava/nio/ByteBuffer;Lcom/google/flatbuffers/FlatBufferBuilder$ByteBufferFactory;)Ljava/nio/ByteBuffer;
|
|
.locals 3
|
|
|
|
.line 1
|
|
invoke-virtual {p0}, Ljava/nio/ByteBuffer;->capacity()I
|
|
|
|
move-result v0
|
|
|
|
const/high16 v1, -0x40000000 # -2.0f
|
|
|
|
and-int/2addr v1, v0
|
|
|
|
if-nez v1, :cond_1
|
|
|
|
if-nez v0, :cond_0
|
|
|
|
const/4 v1, 0x1
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
shl-int/lit8 v1, v0, 0x1
|
|
|
|
:goto_0
|
|
const/4 v2, 0x0
|
|
|
|
.line 2
|
|
invoke-virtual {p0, v2}, Ljava/nio/ByteBuffer;->position(I)Ljava/nio/Buffer;
|
|
|
|
.line 3
|
|
invoke-virtual {p1, v1}, Lcom/google/flatbuffers/FlatBufferBuilder$ByteBufferFactory;->newByteBuffer(I)Ljava/nio/ByteBuffer;
|
|
|
|
move-result-object p1
|
|
|
|
sub-int/2addr v1, v0
|
|
|
|
.line 4
|
|
invoke-virtual {p1, v1}, Ljava/nio/ByteBuffer;->position(I)Ljava/nio/Buffer;
|
|
|
|
.line 5
|
|
invoke-virtual {p1, p0}, Ljava/nio/ByteBuffer;->put(Ljava/nio/ByteBuffer;)Ljava/nio/ByteBuffer;
|
|
|
|
return-object p1
|
|
|
|
.line 6
|
|
:cond_1
|
|
new-instance p0, Ljava/lang/AssertionError;
|
|
|
|
const-string p1, "FlatBuffers: cannot grow buffer beyond 2 gigabytes."
|
|
|
|
invoke-direct {p0, p1}, Ljava/lang/AssertionError;-><init>(Ljava/lang/Object;)V
|
|
|
|
throw p0
|
|
.end method
|
|
|
|
|
|
# virtual methods
|
|
.method public Nested(I)V
|
|
.locals 1
|
|
|
|
.line 1
|
|
invoke-virtual {p0}, Lcom/google/flatbuffers/FlatBufferBuilder;->offset()I
|
|
|
|
move-result v0
|
|
|
|
if-ne p1, v0, :cond_0
|
|
|
|
return-void
|
|
|
|
.line 2
|
|
:cond_0
|
|
new-instance p1, Ljava/lang/AssertionError;
|
|
|
|
const-string v0, "FlatBuffers: struct must be serialized inline."
|
|
|
|
invoke-direct {p1, v0}, Ljava/lang/AssertionError;-><init>(Ljava/lang/Object;)V
|
|
|
|
throw p1
|
|
.end method
|
|
|
|
.method public addBoolean(IZZ)V
|
|
.locals 1
|
|
|
|
.line 2
|
|
iget-boolean v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->force_defaults:Z
|
|
|
|
if-nez v0, :cond_0
|
|
|
|
if-eq p2, p3, :cond_1
|
|
|
|
:cond_0
|
|
invoke-virtual {p0, p2}, Lcom/google/flatbuffers/FlatBufferBuilder;->addBoolean(Z)V
|
|
|
|
invoke-virtual {p0, p1}, Lcom/google/flatbuffers/FlatBufferBuilder;->slot(I)V
|
|
|
|
:cond_1
|
|
return-void
|
|
.end method
|
|
|
|
.method public addBoolean(Z)V
|
|
.locals 2
|
|
|
|
const/4 v0, 0x1
|
|
|
|
const/4 v1, 0x0
|
|
|
|
.line 1
|
|
invoke-virtual {p0, v0, v1}, Lcom/google/flatbuffers/FlatBufferBuilder;->prep(II)V
|
|
|
|
invoke-virtual {p0, p1}, Lcom/google/flatbuffers/FlatBufferBuilder;->putBoolean(Z)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public addByte(B)V
|
|
.locals 2
|
|
|
|
const/4 v0, 0x1
|
|
|
|
const/4 v1, 0x0
|
|
|
|
.line 1
|
|
invoke-virtual {p0, v0, v1}, Lcom/google/flatbuffers/FlatBufferBuilder;->prep(II)V
|
|
|
|
invoke-virtual {p0, p1}, Lcom/google/flatbuffers/FlatBufferBuilder;->putByte(B)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public addByte(IBI)V
|
|
.locals 1
|
|
|
|
.line 2
|
|
iget-boolean v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->force_defaults:Z
|
|
|
|
if-nez v0, :cond_0
|
|
|
|
if-eq p2, p3, :cond_1
|
|
|
|
:cond_0
|
|
invoke-virtual {p0, p2}, Lcom/google/flatbuffers/FlatBufferBuilder;->addByte(B)V
|
|
|
|
invoke-virtual {p0, p1}, Lcom/google/flatbuffers/FlatBufferBuilder;->slot(I)V
|
|
|
|
:cond_1
|
|
return-void
|
|
.end method
|
|
|
|
.method public addDouble(D)V
|
|
.locals 2
|
|
|
|
const/16 v0, 0x8
|
|
|
|
const/4 v1, 0x0
|
|
|
|
.line 1
|
|
invoke-virtual {p0, v0, v1}, Lcom/google/flatbuffers/FlatBufferBuilder;->prep(II)V
|
|
|
|
invoke-virtual {p0, p1, p2}, Lcom/google/flatbuffers/FlatBufferBuilder;->putDouble(D)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public addDouble(IDD)V
|
|
.locals 1
|
|
|
|
.line 2
|
|
iget-boolean v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->force_defaults:Z
|
|
|
|
if-nez v0, :cond_0
|
|
|
|
cmpl-double p4, p2, p4
|
|
|
|
if-eqz p4, :cond_1
|
|
|
|
:cond_0
|
|
invoke-virtual {p0, p2, p3}, Lcom/google/flatbuffers/FlatBufferBuilder;->addDouble(D)V
|
|
|
|
invoke-virtual {p0, p1}, Lcom/google/flatbuffers/FlatBufferBuilder;->slot(I)V
|
|
|
|
:cond_1
|
|
return-void
|
|
.end method
|
|
|
|
.method public addFloat(F)V
|
|
.locals 2
|
|
|
|
const/4 v0, 0x4
|
|
|
|
const/4 v1, 0x0
|
|
|
|
.line 1
|
|
invoke-virtual {p0, v0, v1}, Lcom/google/flatbuffers/FlatBufferBuilder;->prep(II)V
|
|
|
|
invoke-virtual {p0, p1}, Lcom/google/flatbuffers/FlatBufferBuilder;->putFloat(F)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public addFloat(IFD)V
|
|
.locals 2
|
|
|
|
.line 2
|
|
iget-boolean v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->force_defaults:Z
|
|
|
|
if-nez v0, :cond_0
|
|
|
|
float-to-double v0, p2
|
|
|
|
cmpl-double p3, v0, p3
|
|
|
|
if-eqz p3, :cond_1
|
|
|
|
:cond_0
|
|
invoke-virtual {p0, p2}, Lcom/google/flatbuffers/FlatBufferBuilder;->addFloat(F)V
|
|
|
|
invoke-virtual {p0, p1}, Lcom/google/flatbuffers/FlatBufferBuilder;->slot(I)V
|
|
|
|
:cond_1
|
|
return-void
|
|
.end method
|
|
|
|
.method public addInt(I)V
|
|
.locals 2
|
|
|
|
const/4 v0, 0x4
|
|
|
|
const/4 v1, 0x0
|
|
|
|
.line 1
|
|
invoke-virtual {p0, v0, v1}, Lcom/google/flatbuffers/FlatBufferBuilder;->prep(II)V
|
|
|
|
invoke-virtual {p0, p1}, Lcom/google/flatbuffers/FlatBufferBuilder;->putInt(I)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public addInt(III)V
|
|
.locals 1
|
|
|
|
.line 2
|
|
iget-boolean v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->force_defaults:Z
|
|
|
|
if-nez v0, :cond_0
|
|
|
|
if-eq p2, p3, :cond_1
|
|
|
|
:cond_0
|
|
invoke-virtual {p0, p2}, Lcom/google/flatbuffers/FlatBufferBuilder;->addInt(I)V
|
|
|
|
invoke-virtual {p0, p1}, Lcom/google/flatbuffers/FlatBufferBuilder;->slot(I)V
|
|
|
|
:cond_1
|
|
return-void
|
|
.end method
|
|
|
|
.method public addLong(IJJ)V
|
|
.locals 1
|
|
|
|
.line 2
|
|
iget-boolean v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->force_defaults:Z
|
|
|
|
if-nez v0, :cond_0
|
|
|
|
cmp-long p4, p2, p4
|
|
|
|
if-eqz p4, :cond_1
|
|
|
|
:cond_0
|
|
invoke-virtual {p0, p2, p3}, Lcom/google/flatbuffers/FlatBufferBuilder;->addLong(J)V
|
|
|
|
invoke-virtual {p0, p1}, Lcom/google/flatbuffers/FlatBufferBuilder;->slot(I)V
|
|
|
|
:cond_1
|
|
return-void
|
|
.end method
|
|
|
|
.method public addLong(J)V
|
|
.locals 2
|
|
|
|
const/16 v0, 0x8
|
|
|
|
const/4 v1, 0x0
|
|
|
|
.line 1
|
|
invoke-virtual {p0, v0, v1}, Lcom/google/flatbuffers/FlatBufferBuilder;->prep(II)V
|
|
|
|
invoke-virtual {p0, p1, p2}, Lcom/google/flatbuffers/FlatBufferBuilder;->putLong(J)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public addOffset(I)V
|
|
.locals 2
|
|
|
|
const/4 v0, 0x4
|
|
|
|
const/4 v1, 0x0
|
|
|
|
.line 1
|
|
invoke-virtual {p0, v0, v1}, Lcom/google/flatbuffers/FlatBufferBuilder;->prep(II)V
|
|
|
|
.line 2
|
|
invoke-virtual {p0}, Lcom/google/flatbuffers/FlatBufferBuilder;->offset()I
|
|
|
|
move-result v1
|
|
|
|
sub-int/2addr v1, p1
|
|
|
|
add-int/2addr v1, v0
|
|
|
|
.line 3
|
|
invoke-virtual {p0, v1}, Lcom/google/flatbuffers/FlatBufferBuilder;->putInt(I)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public addOffset(III)V
|
|
.locals 1
|
|
|
|
.line 4
|
|
iget-boolean v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->force_defaults:Z
|
|
|
|
if-nez v0, :cond_0
|
|
|
|
if-eq p2, p3, :cond_1
|
|
|
|
:cond_0
|
|
invoke-virtual {p0, p2}, Lcom/google/flatbuffers/FlatBufferBuilder;->addOffset(I)V
|
|
|
|
invoke-virtual {p0, p1}, Lcom/google/flatbuffers/FlatBufferBuilder;->slot(I)V
|
|
|
|
:cond_1
|
|
return-void
|
|
.end method
|
|
|
|
.method public addShort(ISI)V
|
|
.locals 1
|
|
|
|
.line 2
|
|
iget-boolean v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->force_defaults:Z
|
|
|
|
if-nez v0, :cond_0
|
|
|
|
if-eq p2, p3, :cond_1
|
|
|
|
:cond_0
|
|
invoke-virtual {p0, p2}, Lcom/google/flatbuffers/FlatBufferBuilder;->addShort(S)V
|
|
|
|
invoke-virtual {p0, p1}, Lcom/google/flatbuffers/FlatBufferBuilder;->slot(I)V
|
|
|
|
:cond_1
|
|
return-void
|
|
.end method
|
|
|
|
.method public addShort(S)V
|
|
.locals 2
|
|
|
|
const/4 v0, 0x2
|
|
|
|
const/4 v1, 0x0
|
|
|
|
.line 1
|
|
invoke-virtual {p0, v0, v1}, Lcom/google/flatbuffers/FlatBufferBuilder;->prep(II)V
|
|
|
|
invoke-virtual {p0, p1}, Lcom/google/flatbuffers/FlatBufferBuilder;->putShort(S)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public addStruct(III)V
|
|
.locals 0
|
|
|
|
if-eq p2, p3, :cond_0
|
|
|
|
.line 1
|
|
invoke-virtual {p0, p2}, Lcom/google/flatbuffers/FlatBufferBuilder;->Nested(I)V
|
|
|
|
.line 2
|
|
invoke-virtual {p0, p1}, Lcom/google/flatbuffers/FlatBufferBuilder;->slot(I)V
|
|
|
|
:cond_0
|
|
return-void
|
|
.end method
|
|
|
|
.method public clear()V
|
|
.locals 3
|
|
|
|
.line 1
|
|
iget-object v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
invoke-virtual {v0}, Ljava/nio/ByteBuffer;->capacity()I
|
|
|
|
move-result v0
|
|
|
|
iput v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
.line 2
|
|
iget-object v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
invoke-virtual {v0}, Ljava/nio/ByteBuffer;->clear()Ljava/nio/Buffer;
|
|
|
|
const/4 v0, 0x1
|
|
|
|
.line 3
|
|
iput v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->minalign:I
|
|
|
|
.line 4
|
|
:goto_0
|
|
iget v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->vtable_in_use:I
|
|
|
|
const/4 v1, 0x0
|
|
|
|
if-lez v0, :cond_0
|
|
|
|
iget-object v2, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->vtable:[I
|
|
|
|
add-int/lit8 v0, v0, -0x1
|
|
|
|
iput v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->vtable_in_use:I
|
|
|
|
aput v1, v2, v0
|
|
|
|
goto :goto_0
|
|
|
|
.line 5
|
|
:cond_0
|
|
iput v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->vtable_in_use:I
|
|
|
|
.line 6
|
|
iput-boolean v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->nested:Z
|
|
|
|
.line 7
|
|
iput-boolean v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->finished:Z
|
|
|
|
.line 8
|
|
iput v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->object_start:I
|
|
|
|
.line 9
|
|
iput v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->num_vtables:I
|
|
|
|
.line 10
|
|
iput v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->vector_num_elems:I
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public createByteVector([B)I
|
|
.locals 3
|
|
|
|
.line 1
|
|
array-length v0, p1
|
|
|
|
const/4 v1, 0x1
|
|
|
|
.line 2
|
|
invoke-virtual {p0, v1, v0, v1}, Lcom/google/flatbuffers/FlatBufferBuilder;->startVector(III)V
|
|
|
|
.line 3
|
|
iget-object v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
iget v2, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
sub-int/2addr v2, v0
|
|
|
|
iput v2, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
invoke-virtual {v1, v2}, Ljava/nio/ByteBuffer;->position(I)Ljava/nio/Buffer;
|
|
|
|
.line 4
|
|
iget-object v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
invoke-virtual {v0, p1}, Ljava/nio/ByteBuffer;->put([B)Ljava/nio/ByteBuffer;
|
|
|
|
.line 5
|
|
invoke-virtual {p0}, Lcom/google/flatbuffers/FlatBufferBuilder;->endVector()I
|
|
|
|
move-result p1
|
|
|
|
return p1
|
|
.end method
|
|
|
|
.method public createSortedVectorOfTables(Lcom/google/flatbuffers/Table;[I)I
|
|
.locals 1
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"<T:",
|
|
"Lcom/google/flatbuffers/Table;",
|
|
">(TT;[I)I"
|
|
}
|
|
.end annotation
|
|
|
|
.line 1
|
|
iget-object v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
invoke-virtual {p1, p2, v0}, Lcom/google/flatbuffers/Table;->sortTables([ILjava/nio/ByteBuffer;)V
|
|
|
|
.line 2
|
|
invoke-virtual {p0, p2}, Lcom/google/flatbuffers/FlatBufferBuilder;->createVectorOfTables([I)I
|
|
|
|
move-result p1
|
|
|
|
return p1
|
|
.end method
|
|
|
|
.method public createString(Ljava/lang/CharSequence;)I
|
|
.locals 3
|
|
|
|
.line 1
|
|
iget-object v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->utf8:Lcom/google/flatbuffers/Utf8;
|
|
|
|
invoke-virtual {v0, p1}, Lcom/google/flatbuffers/Utf8;->encodedLength(Ljava/lang/CharSequence;)I
|
|
|
|
move-result v0
|
|
|
|
const/4 v1, 0x0
|
|
|
|
.line 2
|
|
invoke-virtual {p0, v1}, Lcom/google/flatbuffers/FlatBufferBuilder;->addByte(B)V
|
|
|
|
const/4 v1, 0x1
|
|
|
|
.line 3
|
|
invoke-virtual {p0, v1, v0, v1}, Lcom/google/flatbuffers/FlatBufferBuilder;->startVector(III)V
|
|
|
|
.line 4
|
|
iget-object v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
iget v2, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
sub-int/2addr v2, v0
|
|
|
|
iput v2, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
invoke-virtual {v1, v2}, Ljava/nio/ByteBuffer;->position(I)Ljava/nio/Buffer;
|
|
|
|
.line 5
|
|
iget-object v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->utf8:Lcom/google/flatbuffers/Utf8;
|
|
|
|
iget-object v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
invoke-virtual {v0, p1, v1}, Lcom/google/flatbuffers/Utf8;->encodeUtf8(Ljava/lang/CharSequence;Ljava/nio/ByteBuffer;)V
|
|
|
|
.line 6
|
|
invoke-virtual {p0}, Lcom/google/flatbuffers/FlatBufferBuilder;->endVector()I
|
|
|
|
move-result p1
|
|
|
|
return p1
|
|
.end method
|
|
|
|
.method public createString(Ljava/nio/ByteBuffer;)I
|
|
.locals 3
|
|
|
|
.line 7
|
|
invoke-virtual {p1}, Ljava/nio/ByteBuffer;->remaining()I
|
|
|
|
move-result v0
|
|
|
|
const/4 v1, 0x0
|
|
|
|
.line 8
|
|
invoke-virtual {p0, v1}, Lcom/google/flatbuffers/FlatBufferBuilder;->addByte(B)V
|
|
|
|
const/4 v1, 0x1
|
|
|
|
.line 9
|
|
invoke-virtual {p0, v1, v0, v1}, Lcom/google/flatbuffers/FlatBufferBuilder;->startVector(III)V
|
|
|
|
.line 10
|
|
iget-object v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
iget v2, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
sub-int/2addr v2, v0
|
|
|
|
iput v2, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
invoke-virtual {v1, v2}, Ljava/nio/ByteBuffer;->position(I)Ljava/nio/Buffer;
|
|
|
|
.line 11
|
|
iget-object v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
invoke-virtual {v0, p1}, Ljava/nio/ByteBuffer;->put(Ljava/nio/ByteBuffer;)Ljava/nio/ByteBuffer;
|
|
|
|
.line 12
|
|
invoke-virtual {p0}, Lcom/google/flatbuffers/FlatBufferBuilder;->endVector()I
|
|
|
|
move-result p1
|
|
|
|
return p1
|
|
.end method
|
|
|
|
.method public createUnintializedVector(III)Ljava/nio/ByteBuffer;
|
|
.locals 1
|
|
|
|
mul-int v0, p1, p2
|
|
|
|
.line 1
|
|
invoke-virtual {p0, p1, p2, p3}, Lcom/google/flatbuffers/FlatBufferBuilder;->startVector(III)V
|
|
|
|
.line 2
|
|
iget-object p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
iget p2, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
sub-int/2addr p2, v0
|
|
|
|
iput p2, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
invoke-virtual {p1, p2}, Ljava/nio/ByteBuffer;->position(I)Ljava/nio/Buffer;
|
|
|
|
.line 3
|
|
iget-object p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
invoke-virtual {p1}, Ljava/nio/ByteBuffer;->slice()Ljava/nio/ByteBuffer;
|
|
|
|
move-result-object p1
|
|
|
|
sget-object p2, Ljava/nio/ByteOrder;->LITTLE_ENDIAN:Ljava/nio/ByteOrder;
|
|
|
|
invoke-virtual {p1, p2}, Ljava/nio/ByteBuffer;->order(Ljava/nio/ByteOrder;)Ljava/nio/ByteBuffer;
|
|
|
|
move-result-object p1
|
|
|
|
.line 4
|
|
invoke-virtual {p1, v0}, Ljava/nio/ByteBuffer;->limit(I)Ljava/nio/Buffer;
|
|
|
|
return-object p1
|
|
.end method
|
|
|
|
.method public createVectorOfTables([I)I
|
|
.locals 2
|
|
|
|
.line 1
|
|
invoke-virtual {p0}, Lcom/google/flatbuffers/FlatBufferBuilder;->notNested()V
|
|
|
|
.line 2
|
|
array-length v0, p1
|
|
|
|
const/4 v1, 0x4
|
|
|
|
invoke-virtual {p0, v1, v0, v1}, Lcom/google/flatbuffers/FlatBufferBuilder;->startVector(III)V
|
|
|
|
.line 3
|
|
array-length v0, p1
|
|
|
|
add-int/lit8 v0, v0, -0x1
|
|
|
|
:goto_0
|
|
if-ltz v0, :cond_0
|
|
|
|
aget v1, p1, v0
|
|
|
|
invoke-virtual {p0, v1}, Lcom/google/flatbuffers/FlatBufferBuilder;->addOffset(I)V
|
|
|
|
add-int/lit8 v0, v0, -0x1
|
|
|
|
goto :goto_0
|
|
|
|
.line 4
|
|
:cond_0
|
|
invoke-virtual {p0}, Lcom/google/flatbuffers/FlatBufferBuilder;->endVector()I
|
|
|
|
move-result p1
|
|
|
|
return p1
|
|
.end method
|
|
|
|
.method public dataBuffer()Ljava/nio/ByteBuffer;
|
|
.locals 1
|
|
|
|
.line 1
|
|
invoke-virtual {p0}, Lcom/google/flatbuffers/FlatBufferBuilder;->finished()V
|
|
|
|
.line 2
|
|
iget-object v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method public endObject()I
|
|
.locals 11
|
|
|
|
.line 1
|
|
iget-object v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->vtable:[I
|
|
|
|
if-eqz v0, :cond_9
|
|
|
|
iget-boolean v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->nested:Z
|
|
|
|
if-eqz v0, :cond_9
|
|
|
|
const/4 v0, 0x0
|
|
|
|
.line 2
|
|
invoke-virtual {p0, v0}, Lcom/google/flatbuffers/FlatBufferBuilder;->addInt(I)V
|
|
|
|
.line 3
|
|
invoke-virtual {p0}, Lcom/google/flatbuffers/FlatBufferBuilder;->offset()I
|
|
|
|
move-result v1
|
|
|
|
.line 4
|
|
iget v2, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->vtable_in_use:I
|
|
|
|
add-int/lit8 v2, v2, -0x1
|
|
|
|
:goto_0
|
|
if-ltz v2, :cond_0
|
|
|
|
.line 5
|
|
iget-object v3, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->vtable:[I
|
|
|
|
aget v3, v3, v2
|
|
|
|
if-nez v3, :cond_0
|
|
|
|
add-int/lit8 v2, v2, -0x1
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
add-int/lit8 v3, v2, 0x1
|
|
|
|
:goto_1
|
|
if-ltz v2, :cond_2
|
|
|
|
.line 6
|
|
iget-object v4, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->vtable:[I
|
|
|
|
aget v5, v4, v2
|
|
|
|
if-eqz v5, :cond_1
|
|
|
|
aget v4, v4, v2
|
|
|
|
sub-int v4, v1, v4
|
|
|
|
goto :goto_2
|
|
|
|
:cond_1
|
|
move v4, v0
|
|
|
|
:goto_2
|
|
int-to-short v4, v4
|
|
|
|
.line 7
|
|
invoke-virtual {p0, v4}, Lcom/google/flatbuffers/FlatBufferBuilder;->addShort(S)V
|
|
|
|
add-int/lit8 v2, v2, -0x1
|
|
|
|
goto :goto_1
|
|
|
|
.line 8
|
|
:cond_2
|
|
iget v2, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->object_start:I
|
|
|
|
sub-int v2, v1, v2
|
|
|
|
int-to-short v2, v2
|
|
|
|
invoke-virtual {p0, v2}, Lcom/google/flatbuffers/FlatBufferBuilder;->addShort(S)V
|
|
|
|
const/4 v2, 0x2
|
|
|
|
add-int/2addr v3, v2
|
|
|
|
mul-int/2addr v3, v2
|
|
|
|
int-to-short v3, v3
|
|
|
|
.line 9
|
|
invoke-virtual {p0, v3}, Lcom/google/flatbuffers/FlatBufferBuilder;->addShort(S)V
|
|
|
|
move v3, v0
|
|
|
|
.line 10
|
|
:goto_3
|
|
iget v4, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->num_vtables:I
|
|
|
|
if-ge v3, v4, :cond_6
|
|
|
|
.line 11
|
|
iget-object v4, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
invoke-virtual {v4}, Ljava/nio/ByteBuffer;->capacity()I
|
|
|
|
move-result v4
|
|
|
|
iget-object v5, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->vtables:[I
|
|
|
|
aget v5, v5, v3
|
|
|
|
sub-int/2addr v4, v5
|
|
|
|
.line 12
|
|
iget v5, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
.line 13
|
|
iget-object v6, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
invoke-virtual {v6, v4}, Ljava/nio/ByteBuffer;->getShort(I)S
|
|
|
|
move-result v6
|
|
|
|
.line 14
|
|
iget-object v7, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
invoke-virtual {v7, v5}, Ljava/nio/ByteBuffer;->getShort(I)S
|
|
|
|
move-result v7
|
|
|
|
if-ne v6, v7, :cond_5
|
|
|
|
move v7, v2
|
|
|
|
:goto_4
|
|
if-ge v7, v6, :cond_4
|
|
|
|
.line 15
|
|
iget-object v8, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
add-int v9, v4, v7
|
|
|
|
invoke-virtual {v8, v9}, Ljava/nio/ByteBuffer;->getShort(I)S
|
|
|
|
move-result v8
|
|
|
|
iget-object v9, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
add-int v10, v5, v7
|
|
|
|
invoke-virtual {v9, v10}, Ljava/nio/ByteBuffer;->getShort(I)S
|
|
|
|
move-result v9
|
|
|
|
if-eq v8, v9, :cond_3
|
|
|
|
goto :goto_5
|
|
|
|
:cond_3
|
|
add-int/lit8 v7, v7, 0x2
|
|
|
|
goto :goto_4
|
|
|
|
.line 16
|
|
:cond_4
|
|
iget-object v4, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->vtables:[I
|
|
|
|
aget v3, v4, v3
|
|
|
|
goto :goto_6
|
|
|
|
:cond_5
|
|
:goto_5
|
|
add-int/lit8 v3, v3, 0x1
|
|
|
|
goto :goto_3
|
|
|
|
:cond_6
|
|
move v3, v0
|
|
|
|
:goto_6
|
|
if-eqz v3, :cond_7
|
|
|
|
.line 17
|
|
iget-object v2, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
invoke-virtual {v2}, Ljava/nio/ByteBuffer;->capacity()I
|
|
|
|
move-result v2
|
|
|
|
sub-int/2addr v2, v1
|
|
|
|
iput v2, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
.line 18
|
|
iget-object v4, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
sub-int/2addr v3, v1
|
|
|
|
invoke-virtual {v4, v2, v3}, Ljava/nio/ByteBuffer;->putInt(II)Ljava/nio/ByteBuffer;
|
|
|
|
goto :goto_7
|
|
|
|
.line 19
|
|
:cond_7
|
|
iget v3, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->num_vtables:I
|
|
|
|
iget-object v4, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->vtables:[I
|
|
|
|
array-length v5, v4
|
|
|
|
if-ne v3, v5, :cond_8
|
|
|
|
mul-int/2addr v3, v2
|
|
|
|
invoke-static {v4, v3}, Ljava/util/Arrays;->copyOf([II)[I
|
|
|
|
move-result-object v2
|
|
|
|
iput-object v2, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->vtables:[I
|
|
|
|
.line 20
|
|
:cond_8
|
|
iget-object v2, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->vtables:[I
|
|
|
|
iget v3, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->num_vtables:I
|
|
|
|
add-int/lit8 v4, v3, 0x1
|
|
|
|
iput v4, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->num_vtables:I
|
|
|
|
invoke-virtual {p0}, Lcom/google/flatbuffers/FlatBufferBuilder;->offset()I
|
|
|
|
move-result v4
|
|
|
|
aput v4, v2, v3
|
|
|
|
.line 21
|
|
iget-object v2, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
invoke-virtual {v2}, Ljava/nio/ByteBuffer;->capacity()I
|
|
|
|
move-result v3
|
|
|
|
sub-int/2addr v3, v1
|
|
|
|
invoke-virtual {p0}, Lcom/google/flatbuffers/FlatBufferBuilder;->offset()I
|
|
|
|
move-result v4
|
|
|
|
sub-int/2addr v4, v1
|
|
|
|
invoke-virtual {v2, v3, v4}, Ljava/nio/ByteBuffer;->putInt(II)Ljava/nio/ByteBuffer;
|
|
|
|
.line 22
|
|
:goto_7
|
|
iput-boolean v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->nested:Z
|
|
|
|
return v1
|
|
|
|
.line 23
|
|
:cond_9
|
|
new-instance v0, Ljava/lang/AssertionError;
|
|
|
|
const-string v1, "FlatBuffers: endObject called without startObject"
|
|
|
|
invoke-direct {v0, v1}, Ljava/lang/AssertionError;-><init>(Ljava/lang/Object;)V
|
|
|
|
throw v0
|
|
.end method
|
|
|
|
.method public endVector()I
|
|
.locals 2
|
|
|
|
.line 1
|
|
iget-boolean v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->nested:Z
|
|
|
|
if-eqz v0, :cond_0
|
|
|
|
const/4 v0, 0x0
|
|
|
|
.line 2
|
|
iput-boolean v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->nested:Z
|
|
|
|
.line 3
|
|
iget v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->vector_num_elems:I
|
|
|
|
invoke-virtual {p0, v0}, Lcom/google/flatbuffers/FlatBufferBuilder;->putInt(I)V
|
|
|
|
.line 4
|
|
invoke-virtual {p0}, Lcom/google/flatbuffers/FlatBufferBuilder;->offset()I
|
|
|
|
move-result v0
|
|
|
|
return v0
|
|
|
|
.line 5
|
|
:cond_0
|
|
new-instance v0, Ljava/lang/AssertionError;
|
|
|
|
const-string v1, "FlatBuffers: endVector called without startVector"
|
|
|
|
invoke-direct {v0, v1}, Ljava/lang/AssertionError;-><init>(Ljava/lang/Object;)V
|
|
|
|
throw v0
|
|
.end method
|
|
|
|
.method public finish(I)V
|
|
.locals 1
|
|
|
|
const/4 v0, 0x0
|
|
|
|
.line 6
|
|
invoke-virtual {p0, p1, v0}, Lcom/google/flatbuffers/FlatBufferBuilder;->finish(IZ)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public finish(ILjava/lang/String;)V
|
|
.locals 1
|
|
|
|
const/4 v0, 0x0
|
|
|
|
.line 12
|
|
invoke-virtual {p0, p1, p2, v0}, Lcom/google/flatbuffers/FlatBufferBuilder;->finish(ILjava/lang/String;Z)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public finish(ILjava/lang/String;Z)V
|
|
.locals 3
|
|
|
|
.line 7
|
|
iget v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->minalign:I
|
|
|
|
const/4 v1, 0x4
|
|
|
|
if-eqz p3, :cond_0
|
|
|
|
move v2, v1
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
const/4 v2, 0x0
|
|
|
|
:goto_0
|
|
add-int/lit8 v2, v2, 0x8
|
|
|
|
invoke-virtual {p0, v0, v2}, Lcom/google/flatbuffers/FlatBufferBuilder;->prep(II)V
|
|
|
|
.line 8
|
|
invoke-virtual {p2}, Ljava/lang/String;->length()I
|
|
|
|
move-result v0
|
|
|
|
if-ne v0, v1, :cond_2
|
|
|
|
const/4 v0, 0x3
|
|
|
|
:goto_1
|
|
if-ltz v0, :cond_1
|
|
|
|
.line 9
|
|
invoke-virtual {p2, v0}, Ljava/lang/String;->charAt(I)C
|
|
|
|
move-result v1
|
|
|
|
int-to-byte v1, v1
|
|
|
|
invoke-virtual {p0, v1}, Lcom/google/flatbuffers/FlatBufferBuilder;->addByte(B)V
|
|
|
|
add-int/lit8 v0, v0, -0x1
|
|
|
|
goto :goto_1
|
|
|
|
.line 10
|
|
:cond_1
|
|
invoke-virtual {p0, p1, p3}, Lcom/google/flatbuffers/FlatBufferBuilder;->finish(IZ)V
|
|
|
|
return-void
|
|
|
|
.line 11
|
|
:cond_2
|
|
new-instance p1, Ljava/lang/AssertionError;
|
|
|
|
const-string p2, "FlatBuffers: file identifier must be length 4"
|
|
|
|
invoke-direct {p1, p2}, Ljava/lang/AssertionError;-><init>(Ljava/lang/Object;)V
|
|
|
|
throw p1
|
|
.end method
|
|
|
|
.method public finish(IZ)V
|
|
.locals 3
|
|
|
|
.line 1
|
|
iget v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->minalign:I
|
|
|
|
const/4 v1, 0x4
|
|
|
|
if-eqz p2, :cond_0
|
|
|
|
move v2, v1
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
const/4 v2, 0x0
|
|
|
|
:goto_0
|
|
add-int/2addr v2, v1
|
|
|
|
invoke-virtual {p0, v0, v2}, Lcom/google/flatbuffers/FlatBufferBuilder;->prep(II)V
|
|
|
|
.line 2
|
|
invoke-virtual {p0, p1}, Lcom/google/flatbuffers/FlatBufferBuilder;->addOffset(I)V
|
|
|
|
if-eqz p2, :cond_1
|
|
|
|
.line 3
|
|
iget-object p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
invoke-virtual {p1}, Ljava/nio/ByteBuffer;->capacity()I
|
|
|
|
move-result p1
|
|
|
|
iget p2, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
sub-int/2addr p1, p2
|
|
|
|
invoke-virtual {p0, p1}, Lcom/google/flatbuffers/FlatBufferBuilder;->addInt(I)V
|
|
|
|
.line 4
|
|
:cond_1
|
|
iget-object p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
iget p2, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
invoke-virtual {p1, p2}, Ljava/nio/ByteBuffer;->position(I)Ljava/nio/Buffer;
|
|
|
|
const/4 p1, 0x1
|
|
|
|
.line 5
|
|
iput-boolean p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->finished:Z
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public finishSizePrefixed(I)V
|
|
.locals 1
|
|
|
|
const/4 v0, 0x1
|
|
|
|
.line 1
|
|
invoke-virtual {p0, p1, v0}, Lcom/google/flatbuffers/FlatBufferBuilder;->finish(IZ)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public finishSizePrefixed(ILjava/lang/String;)V
|
|
.locals 1
|
|
|
|
const/4 v0, 0x1
|
|
|
|
.line 2
|
|
invoke-virtual {p0, p1, p2, v0}, Lcom/google/flatbuffers/FlatBufferBuilder;->finish(ILjava/lang/String;Z)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public finished()V
|
|
.locals 2
|
|
|
|
.line 1
|
|
iget-boolean v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->finished:Z
|
|
|
|
if-eqz v0, :cond_0
|
|
|
|
return-void
|
|
|
|
.line 2
|
|
:cond_0
|
|
new-instance v0, Ljava/lang/AssertionError;
|
|
|
|
const-string v1, "FlatBuffers: you can only access the serialized buffer after it has been finished by FlatBufferBuilder.finish()."
|
|
|
|
invoke-direct {v0, v1}, Ljava/lang/AssertionError;-><init>(Ljava/lang/Object;)V
|
|
|
|
throw v0
|
|
.end method
|
|
|
|
.method public forceDefaults(Z)Lcom/google/flatbuffers/FlatBufferBuilder;
|
|
.locals 0
|
|
|
|
.line 1
|
|
iput-boolean p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->force_defaults:Z
|
|
|
|
return-object p0
|
|
.end method
|
|
|
|
.method public init(Ljava/nio/ByteBuffer;Lcom/google/flatbuffers/FlatBufferBuilder$ByteBufferFactory;)Lcom/google/flatbuffers/FlatBufferBuilder;
|
|
.locals 0
|
|
|
|
.line 1
|
|
iput-object p2, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb_factory:Lcom/google/flatbuffers/FlatBufferBuilder$ByteBufferFactory;
|
|
|
|
.line 2
|
|
iput-object p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
.line 3
|
|
invoke-virtual {p1}, Ljava/nio/ByteBuffer;->clear()Ljava/nio/Buffer;
|
|
|
|
.line 4
|
|
iget-object p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
sget-object p2, Ljava/nio/ByteOrder;->LITTLE_ENDIAN:Ljava/nio/ByteOrder;
|
|
|
|
invoke-virtual {p1, p2}, Ljava/nio/ByteBuffer;->order(Ljava/nio/ByteOrder;)Ljava/nio/ByteBuffer;
|
|
|
|
const/4 p1, 0x1
|
|
|
|
.line 5
|
|
iput p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->minalign:I
|
|
|
|
.line 6
|
|
iget-object p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
invoke-virtual {p1}, Ljava/nio/ByteBuffer;->capacity()I
|
|
|
|
move-result p1
|
|
|
|
iput p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
const/4 p1, 0x0
|
|
|
|
.line 7
|
|
iput p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->vtable_in_use:I
|
|
|
|
.line 8
|
|
iput-boolean p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->nested:Z
|
|
|
|
.line 9
|
|
iput-boolean p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->finished:Z
|
|
|
|
.line 10
|
|
iput p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->object_start:I
|
|
|
|
.line 11
|
|
iput p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->num_vtables:I
|
|
|
|
.line 12
|
|
iput p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->vector_num_elems:I
|
|
|
|
return-object p0
|
|
.end method
|
|
|
|
.method public notNested()V
|
|
.locals 2
|
|
|
|
.line 1
|
|
iget-boolean v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->nested:Z
|
|
|
|
if-nez v0, :cond_0
|
|
|
|
return-void
|
|
|
|
.line 2
|
|
:cond_0
|
|
new-instance v0, Ljava/lang/AssertionError;
|
|
|
|
const-string v1, "FlatBuffers: object serialization must not be nested."
|
|
|
|
invoke-direct {v0, v1}, Ljava/lang/AssertionError;-><init>(Ljava/lang/Object;)V
|
|
|
|
throw v0
|
|
.end method
|
|
|
|
.method public offset()I
|
|
.locals 2
|
|
|
|
.line 1
|
|
iget-object v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
invoke-virtual {v0}, Ljava/nio/ByteBuffer;->capacity()I
|
|
|
|
move-result v0
|
|
|
|
iget v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
sub-int/2addr v0, v1
|
|
|
|
return v0
|
|
.end method
|
|
|
|
.method public pad(I)V
|
|
.locals 4
|
|
|
|
const/4 v0, 0x0
|
|
|
|
move v1, v0
|
|
|
|
:goto_0
|
|
if-ge v1, p1, :cond_0
|
|
|
|
.line 1
|
|
iget-object v2, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
iget v3, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
add-int/lit8 v3, v3, -0x1
|
|
|
|
iput v3, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
invoke-virtual {v2, v3, v0}, Ljava/nio/ByteBuffer;->put(IB)Ljava/nio/ByteBuffer;
|
|
|
|
add-int/lit8 v1, v1, 0x1
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
return-void
|
|
.end method
|
|
|
|
.method public prep(II)V
|
|
.locals 4
|
|
|
|
.line 1
|
|
iget v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->minalign:I
|
|
|
|
if-le p1, v0, :cond_0
|
|
|
|
iput p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->minalign:I
|
|
|
|
.line 2
|
|
:cond_0
|
|
iget-object v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
invoke-virtual {v0}, Ljava/nio/ByteBuffer;->capacity()I
|
|
|
|
move-result v0
|
|
|
|
iget v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
sub-int/2addr v0, v1
|
|
|
|
add-int/2addr v0, p2
|
|
|
|
not-int v0, v0
|
|
|
|
add-int/lit8 v0, v0, 0x1
|
|
|
|
add-int/lit8 v1, p1, -0x1
|
|
|
|
and-int/2addr v0, v1
|
|
|
|
.line 3
|
|
:goto_0
|
|
iget v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
add-int v2, v0, p1
|
|
|
|
add-int/2addr v2, p2
|
|
|
|
if-ge v1, v2, :cond_2
|
|
|
|
.line 4
|
|
iget-object v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
invoke-virtual {v1}, Ljava/nio/ByteBuffer;->capacity()I
|
|
|
|
move-result v1
|
|
|
|
.line 5
|
|
iget-object v2, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
.line 6
|
|
iget-object v3, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb_factory:Lcom/google/flatbuffers/FlatBufferBuilder$ByteBufferFactory;
|
|
|
|
invoke-static {v2, v3}, Lcom/google/flatbuffers/FlatBufferBuilder;->growByteBuffer(Ljava/nio/ByteBuffer;Lcom/google/flatbuffers/FlatBufferBuilder$ByteBufferFactory;)Ljava/nio/ByteBuffer;
|
|
|
|
move-result-object v3
|
|
|
|
iput-object v3, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
if-eq v2, v3, :cond_1
|
|
|
|
.line 7
|
|
iget-object v3, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb_factory:Lcom/google/flatbuffers/FlatBufferBuilder$ByteBufferFactory;
|
|
|
|
invoke-virtual {v3, v2}, Lcom/google/flatbuffers/FlatBufferBuilder$ByteBufferFactory;->releaseByteBuffer(Ljava/nio/ByteBuffer;)V
|
|
|
|
.line 8
|
|
:cond_1
|
|
iget v2, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
iget-object v3, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
invoke-virtual {v3}, Ljava/nio/ByteBuffer;->capacity()I
|
|
|
|
move-result v3
|
|
|
|
sub-int/2addr v3, v1
|
|
|
|
add-int/2addr v3, v2
|
|
|
|
iput v3, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
goto :goto_0
|
|
|
|
.line 9
|
|
:cond_2
|
|
invoke-virtual {p0, v0}, Lcom/google/flatbuffers/FlatBufferBuilder;->pad(I)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public putBoolean(Z)V
|
|
.locals 2
|
|
|
|
.line 1
|
|
iget-object v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
iget v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
add-int/lit8 v1, v1, -0x1
|
|
|
|
iput v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
int-to-byte p1, p1
|
|
|
|
invoke-virtual {v0, v1, p1}, Ljava/nio/ByteBuffer;->put(IB)Ljava/nio/ByteBuffer;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public putByte(B)V
|
|
.locals 2
|
|
|
|
.line 1
|
|
iget-object v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
iget v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
add-int/lit8 v1, v1, -0x1
|
|
|
|
iput v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
invoke-virtual {v0, v1, p1}, Ljava/nio/ByteBuffer;->put(IB)Ljava/nio/ByteBuffer;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public putDouble(D)V
|
|
.locals 2
|
|
|
|
.line 1
|
|
iget-object v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
iget v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
add-int/lit8 v1, v1, -0x8
|
|
|
|
iput v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
invoke-virtual {v0, v1, p1, p2}, Ljava/nio/ByteBuffer;->putDouble(ID)Ljava/nio/ByteBuffer;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public putFloat(F)V
|
|
.locals 2
|
|
|
|
.line 1
|
|
iget-object v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
iget v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
add-int/lit8 v1, v1, -0x4
|
|
|
|
iput v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
invoke-virtual {v0, v1, p1}, Ljava/nio/ByteBuffer;->putFloat(IF)Ljava/nio/ByteBuffer;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public putInt(I)V
|
|
.locals 2
|
|
|
|
.line 1
|
|
iget-object v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
iget v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
add-int/lit8 v1, v1, -0x4
|
|
|
|
iput v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
invoke-virtual {v0, v1, p1}, Ljava/nio/ByteBuffer;->putInt(II)Ljava/nio/ByteBuffer;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public putLong(J)V
|
|
.locals 2
|
|
|
|
.line 1
|
|
iget-object v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
iget v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
add-int/lit8 v1, v1, -0x8
|
|
|
|
iput v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
invoke-virtual {v0, v1, p1, p2}, Ljava/nio/ByteBuffer;->putLong(IJ)Ljava/nio/ByteBuffer;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public putShort(S)V
|
|
.locals 2
|
|
|
|
.line 1
|
|
iget-object v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
iget v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
add-int/lit8 v1, v1, -0x2
|
|
|
|
iput v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
invoke-virtual {v0, v1, p1}, Ljava/nio/ByteBuffer;->putShort(IS)Ljava/nio/ByteBuffer;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public required(II)V
|
|
.locals 2
|
|
|
|
.line 1
|
|
iget-object v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
invoke-virtual {v0}, Ljava/nio/ByteBuffer;->capacity()I
|
|
|
|
move-result v0
|
|
|
|
sub-int/2addr v0, p1
|
|
|
|
.line 2
|
|
iget-object p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
invoke-virtual {p1, v0}, Ljava/nio/ByteBuffer;->getInt(I)I
|
|
|
|
move-result p1
|
|
|
|
sub-int/2addr v0, p1
|
|
|
|
.line 3
|
|
iget-object p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
add-int/2addr v0, p2
|
|
|
|
invoke-virtual {p1, v0}, Ljava/nio/ByteBuffer;->getShort(I)S
|
|
|
|
move-result p1
|
|
|
|
if-eqz p1, :cond_0
|
|
|
|
const/4 p1, 0x1
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
const/4 p1, 0x0
|
|
|
|
:goto_0
|
|
if-eqz p1, :cond_1
|
|
|
|
return-void
|
|
|
|
.line 4
|
|
:cond_1
|
|
new-instance p1, Ljava/lang/AssertionError;
|
|
|
|
const-string v0, "FlatBuffers: field "
|
|
|
|
const-string v1, " must be set"
|
|
|
|
invoke-static {v0, p2, v1}, Landroidx/camera/core/impl/utils/f;->a(Ljava/lang/String;ILjava/lang/String;)Ljava/lang/String;
|
|
|
|
move-result-object p2
|
|
|
|
invoke-direct {p1, p2}, Ljava/lang/AssertionError;-><init>(Ljava/lang/Object;)V
|
|
|
|
throw p1
|
|
.end method
|
|
|
|
.method public sizedByteArray()[B
|
|
.locals 3
|
|
|
|
.line 5
|
|
iget v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
iget-object v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
invoke-virtual {v1}, Ljava/nio/ByteBuffer;->capacity()I
|
|
|
|
move-result v1
|
|
|
|
iget v2, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
sub-int/2addr v1, v2
|
|
|
|
invoke-virtual {p0, v0, v1}, Lcom/google/flatbuffers/FlatBufferBuilder;->sizedByteArray(II)[B
|
|
|
|
move-result-object v0
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method public sizedByteArray(II)[B
|
|
.locals 1
|
|
|
|
.line 1
|
|
invoke-virtual {p0}, Lcom/google/flatbuffers/FlatBufferBuilder;->finished()V
|
|
|
|
.line 2
|
|
new-array p2, p2, [B
|
|
|
|
.line 3
|
|
iget-object v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
invoke-virtual {v0, p1}, Ljava/nio/ByteBuffer;->position(I)Ljava/nio/Buffer;
|
|
|
|
.line 4
|
|
iget-object p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
invoke-virtual {p1, p2}, Ljava/nio/ByteBuffer;->get([B)Ljava/nio/ByteBuffer;
|
|
|
|
return-object p2
|
|
.end method
|
|
|
|
.method public sizedInputStream()Ljava/io/InputStream;
|
|
.locals 2
|
|
|
|
.line 1
|
|
invoke-virtual {p0}, Lcom/google/flatbuffers/FlatBufferBuilder;->finished()V
|
|
|
|
.line 2
|
|
iget-object v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
invoke-virtual {v0}, Ljava/nio/ByteBuffer;->duplicate()Ljava/nio/ByteBuffer;
|
|
|
|
move-result-object v0
|
|
|
|
.line 3
|
|
iget v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->space:I
|
|
|
|
invoke-virtual {v0, v1}, Ljava/nio/ByteBuffer;->position(I)Ljava/nio/Buffer;
|
|
|
|
.line 4
|
|
iget-object v1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->bb:Ljava/nio/ByteBuffer;
|
|
|
|
invoke-virtual {v1}, Ljava/nio/ByteBuffer;->capacity()I
|
|
|
|
move-result v1
|
|
|
|
invoke-virtual {v0, v1}, Ljava/nio/ByteBuffer;->limit(I)Ljava/nio/Buffer;
|
|
|
|
.line 5
|
|
new-instance v1, Lcom/google/flatbuffers/FlatBufferBuilder$ByteBufferBackedInputStream;
|
|
|
|
invoke-direct {v1, v0}, Lcom/google/flatbuffers/FlatBufferBuilder$ByteBufferBackedInputStream;-><init>(Ljava/nio/ByteBuffer;)V
|
|
|
|
return-object v1
|
|
.end method
|
|
|
|
.method public slot(I)V
|
|
.locals 2
|
|
|
|
.line 1
|
|
iget-object v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->vtable:[I
|
|
|
|
invoke-virtual {p0}, Lcom/google/flatbuffers/FlatBufferBuilder;->offset()I
|
|
|
|
move-result v1
|
|
|
|
aput v1, v0, p1
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public startObject(I)V
|
|
.locals 2
|
|
|
|
.line 1
|
|
invoke-virtual {p0}, Lcom/google/flatbuffers/FlatBufferBuilder;->notNested()V
|
|
|
|
.line 2
|
|
iget-object v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->vtable:[I
|
|
|
|
if-eqz v0, :cond_0
|
|
|
|
array-length v0, v0
|
|
|
|
if-ge v0, p1, :cond_1
|
|
|
|
:cond_0
|
|
new-array v0, p1, [I
|
|
|
|
iput-object v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->vtable:[I
|
|
|
|
.line 3
|
|
:cond_1
|
|
iput p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->vtable_in_use:I
|
|
|
|
.line 4
|
|
iget-object v0, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->vtable:[I
|
|
|
|
const/4 v1, 0x0
|
|
|
|
invoke-static {v0, v1, p1, v1}, Ljava/util/Arrays;->fill([IIII)V
|
|
|
|
const/4 p1, 0x1
|
|
|
|
.line 5
|
|
iput-boolean p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->nested:Z
|
|
|
|
.line 6
|
|
invoke-virtual {p0}, Lcom/google/flatbuffers/FlatBufferBuilder;->offset()I
|
|
|
|
move-result p1
|
|
|
|
iput p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->object_start:I
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public startVector(III)V
|
|
.locals 0
|
|
|
|
.line 1
|
|
invoke-virtual {p0}, Lcom/google/flatbuffers/FlatBufferBuilder;->notNested()V
|
|
|
|
.line 2
|
|
iput p2, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->vector_num_elems:I
|
|
|
|
mul-int/2addr p1, p2
|
|
|
|
const/4 p2, 0x4
|
|
|
|
.line 3
|
|
invoke-virtual {p0, p2, p1}, Lcom/google/flatbuffers/FlatBufferBuilder;->prep(II)V
|
|
|
|
.line 4
|
|
invoke-virtual {p0, p3, p1}, Lcom/google/flatbuffers/FlatBufferBuilder;->prep(II)V
|
|
|
|
const/4 p1, 0x1
|
|
|
|
.line 5
|
|
iput-boolean p1, p0, Lcom/google/flatbuffers/FlatBufferBuilder;->nested:Z
|
|
|
|
return-void
|
|
.end method
|