g.smali

.class public final Lcom/squareup/wire/g;
.super Ljava/lang/Object;
.source "SourceFile"


# instance fields
.field private final a:Lokio/d;


# direct methods
.method public constructor <init>(Lokio/d;)V
    .registers 2

    invoke-direct {p0}, Ljava/lang/Object;-><init>()V

    iput-object p1, p0, Lcom/squareup/wire/g;->a:Lokio/d;

    return-void
.end method

.method static a(I)I
    .registers 2

    ushr-int/lit8 v0, p0, 0x1

    and-int/lit8 p0, p0, 0x1

    neg-int p0, p0

    xor-int/2addr p0, v0

    return p0
.end method

.method static b(J)J
    .registers 6

    const/4 v0, 0x1

    ushr-long v0, p0, v0

    const-wide/16 v2, 0x1

    and-long/2addr p0, v2

    neg-long p0, p0

    xor-long/2addr p0, v0

    return-wide p0
.end method

.method static c(I)I
    .registers 2

    shl-int/lit8 v0, p0, 0x1

    shr-int/lit8 p0, p0, 0x1f

    xor-int/2addr p0, v0

    return p0
.end method

.method static d(J)J
    .registers 5

    const/4 v0, 0x1

    shl-long v0, p0, v0

    const/16 v2, 0x3f

    shr-long/2addr p0, v2

    xor-long/2addr p0, v0

    return-wide p0
.end method

.method static e(I)I
    .registers 1

    if-ltz p0, :cond_7

    invoke-static {p0}, Lcom/squareup/wire/g;->i(I)I

    move-result p0

    return p0

    :cond_7
    const/16 p0, 0xa

    return p0
.end method

.method private static f(ILcom/squareup/wire/a;)I
    .registers 2

    shl-int/lit8 p0, p0, 0x3

    iget p1, p1, Lcom/squareup/wire/a;->a:I

    or-int/2addr p0, p1

    return p0
.end method

.method static g(I)I
    .registers 2

    sget-object v0, Lcom/squareup/wire/a;->b:Lcom/squareup/wire/a;

    invoke-static {p0, v0}, Lcom/squareup/wire/g;->f(ILcom/squareup/wire/a;)I

    move-result p0

    invoke-static {p0}, Lcom/squareup/wire/g;->i(I)I

    move-result p0

    return p0
.end method

.method static h(Ljava/lang/String;)I
    .registers 8

    invoke-virtual {p0}, Ljava/lang/String;->length()I

    move-result v0

    const/4 v1, 0x0

    const/4 v2, 0x0

    :goto_6
    if-ge v1, v0, :cond_46

    invoke-virtual {p0, v1}, Ljava/lang/String;->charAt(I)C

    move-result v3

    const/16 v4, 0x80

    if-ge v3, v4, :cond_13

    :cond_10
    add-int/lit8 v2, v2, 0x1

    goto :goto_43

    :cond_13
    const/16 v4, 0x800

    if-ge v3, v4, :cond_1a

    add-int/lit8 v2, v2, 0x2

    goto :goto_43

    :cond_1a
    const v4, 0xd800

    if-lt v3, v4, :cond_41

    const v4, 0xdfff

    if-le v3, v4, :cond_25

    goto :goto_41

    :cond_25
    const v5, 0xdbff

    if-gt v3, v5, :cond_10

    add-int/lit8 v3, v1, 0x1

    if-ge v3, v0, :cond_10

    invoke-virtual {p0, v3}, Ljava/lang/String;->charAt(I)C

    move-result v5

    const v6, 0xdc00

    if-lt v5, v6, :cond_10

    invoke-virtual {p0, v3}, Ljava/lang/String;->charAt(I)C

    move-result v5

    if-gt v5, v4, :cond_10

    add-int/lit8 v2, v2, 0x4

    move v1, v3

    goto :goto_43

    :cond_41
    :goto_41
    add-int/lit8 v2, v2, 0x3

    :goto_43
    add-int/lit8 v1, v1, 0x1

    goto :goto_6

    :cond_46
    return v2
.end method

.method static i(I)I
    .registers 2

    and-int/lit8 v0, p0, -0x80

    if-nez v0, :cond_6

    const/4 p0, 0x1

    return p0

    :cond_6
    and-int/lit16 v0, p0, -0x4000

    if-nez v0, :cond_c

    const/4 p0, 0x2

    return p0

    :cond_c
    const/high16 v0, -0x200000

    and-int/2addr v0, p0

    if-nez v0, :cond_13

    const/4 p0, 0x3

    return p0

    :cond_13
    const/high16 v0, -0x10000000

    and-int/2addr p0, v0

    if-nez p0, :cond_1a

    const/4 p0, 0x4

    return p0

    :cond_1a
    const/4 p0, 0x5

    return p0
.end method

.method static j(J)I
    .registers 7

    const-wide/16 v0, -0x80

    and-long/2addr v0, p0

    const-wide/16 v2, 0x0

    cmp-long v4, v0, v2

    if-nez v4, :cond_b

    const/4 p0, 0x1

    return p0

    :cond_b
    const-wide/16 v0, -0x4000

    and-long/2addr v0, p0

    cmp-long v4, v0, v2

    if-nez v4, :cond_14

    const/4 p0, 0x2

    return p0

    :cond_14
    const-wide/32 v0, -0x200000

    and-long/2addr v0, p0

    cmp-long v4, v0, v2

    if-nez v4, :cond_1e

    const/4 p0, 0x3

    return p0

    :cond_1e
    const-wide/32 v0, -0x10000000

    and-long/2addr v0, p0

    cmp-long v4, v0, v2

    if-nez v4, :cond_28

    const/4 p0, 0x4

    return p0

    :cond_28
    const-wide v0, -0x800000000L

    and-long/2addr v0, p0

    cmp-long v4, v0, v2

    if-nez v4, :cond_34

    const/4 p0, 0x5

    return p0

    :cond_34
    const-wide v0, -0x40000000000L

    and-long/2addr v0, p0

    cmp-long v4, v0, v2

    if-nez v4, :cond_40

    const/4 p0, 0x6

    return p0

    :cond_40
    const-wide/high16 v0, -0x2000000000000L

    and-long/2addr v0, p0

    cmp-long v4, v0, v2

    if-nez v4, :cond_49

    const/4 p0, 0x7

    return p0

    :cond_49
    const-wide/high16 v0, -0x100000000000000L

    and-long/2addr v0, p0

    cmp-long v4, v0, v2

    if-nez v4, :cond_53

    const/16 p0, 0x8

    return p0

    :cond_53
    const-wide/high16 v0, -0x8000000000000000L

    and-long/2addr p0, v0

    cmp-long v0, p0, v2

    if-nez v0, :cond_5d

    const/16 p0, 0x9

    return p0

    :cond_5d
    const/16 p0, 0xa

    return p0
.end method


# virtual methods
.method public k(Lokio/f;)V
    .registers 3

    iget-object v0, p0, Lcom/squareup/wire/g;->a:Lokio/d;

    invoke-interface {v0, p1}, Lokio/d;->j0(Lokio/f;)Lokio/d;

    return-void
.end method

.method public l(I)V
    .registers 3

    iget-object v0, p0, Lcom/squareup/wire/g;->a:Lokio/d;

    invoke-interface {v0, p1}, Lokio/d;->G(I)Lokio/d;

    return-void
.end method

.method public m(J)V
    .registers 4

    iget-object v0, p0, Lcom/squareup/wire/g;->a:Lokio/d;

    invoke-interface {v0, p1, p2}, Lokio/d;->A(J)Lokio/d;

    return-void
.end method

.method n(I)V
    .registers 4

    if-ltz p1, :cond_6

    invoke-virtual {p0, p1}, Lcom/squareup/wire/g;->q(I)V

    goto :goto_a

    :cond_6
    int-to-long v0, p1

    invoke-virtual {p0, v0, v1}, Lcom/squareup/wire/g;->r(J)V

    :goto_a
    return-void
.end method

.method public o(Ljava/lang/String;)V
    .registers 3

    iget-object v0, p0, Lcom/squareup/wire/g;->a:Lokio/d;

    invoke-interface {v0, p1}, Lokio/d;->Q(Ljava/lang/String;)Lokio/d;

    return-void
.end method

.method public p(ILcom/squareup/wire/a;)V
    .registers 3

    invoke-static {p1, p2}, Lcom/squareup/wire/g;->f(ILcom/squareup/wire/a;)I

    move-result p1

    invoke-virtual {p0, p1}, Lcom/squareup/wire/g;->q(I)V

    return-void
.end method

.method public q(I)V
    .registers 4

    :goto_0
    and-int/lit8 v0, p1, -0x80

    if-eqz v0, :cond_10

    iget-object v0, p0, Lcom/squareup/wire/g;->a:Lokio/d;

    and-int/lit8 v1, p1, 0x7f

    or-int/lit16 v1, v1, 0x80

    invoke-interface {v0, v1}, Lokio/d;->writeByte(I)Lokio/d;

    ushr-int/lit8 p1, p1, 0x7

    goto :goto_0

    :cond_10
    iget-object v0, p0, Lcom/squareup/wire/g;->a:Lokio/d;

    invoke-interface {v0, p1}, Lokio/d;->writeByte(I)Lokio/d;

    return-void
.end method

.method public r(J)V
    .registers 8

    :goto_0
    const-wide/16 v0, -0x80

    and-long/2addr v0, p1

    const-wide/16 v2, 0x0

    cmp-long v4, v0, v2

    iget-object v0, p0, Lcom/squareup/wire/g;->a:Lokio/d;

    if-eqz v4, :cond_16

    long-to-int v1, p1

    and-int/lit8 v1, v1, 0x7f

    or-int/lit16 v1, v1, 0x80

    invoke-interface {v0, v1}, Lokio/d;->writeByte(I)Lokio/d;

    const/4 v0, 0x7

    ushr-long/2addr p1, v0

    goto :goto_0

    :cond_16
    long-to-int p2, p1

    invoke-interface {v0, p2}, Lokio/d;->writeByte(I)Lokio/d;

    return-void
.end method