.class public Lc2/a;
.super Lv2/e;
.source ""


# annotations
.annotation system Ldalvik/annotation/MemberClasses;
    value = {
        Lc2/a$a;
    }
.end annotation


# instance fields
.field public v:[I

.field public w:Lc2/a$a;

.field public x:Ljava/lang/String;

.field public y:Ljava/util/Map;
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "Ljava/util/Map<",
            "Ljava/lang/String;",
            "Ljava/lang/String;",
            ">;"
        }
    .end annotation
.end field


# direct methods
.method public constructor <init>()V
    .registers 3

    invoke-direct {p0}, Lv2/e;-><init>()V

    const/4 v0, 0x2

    new-array v0, v0, [I

    iput-object v0, p0, Lc2/a;->v:[I

    new-instance v0, Lc2/a$a;

    const/4 v1, 0x0

    new-array v1, v1, [Ljava/lang/String;

    invoke-direct {v0, v1}, Lc2/a$a;-><init>([Ljava/lang/String;)V

    iput-object v0, p0, Lc2/a;->w:Lc2/a$a;

    const/4 v0, 0x0

    iput-object v0, p0, Lc2/a;->x:Ljava/lang/String;

    iput-object v0, p0, Lc2/a;->y:Ljava/util/Map;

    return-void
.end method


# virtual methods
.method public d(Lorg/xml/sax/InputSource;)Ljava/util/List;
    .registers 8
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "(",
            "Lorg/xml/sax/InputSource;",
            ")",
            "Ljava/util/List<",
            "Lv2/d;",
            ">;"
        }
    .end annotation

    invoke-virtual {p1}, Lorg/xml/sax/InputSource;->getByteStream()Ljava/io/InputStream;

    move-result-object p1

    if-eqz p1, :cond_9d

    :try_start_6
    new-instance v0, Lz1/a;

    invoke-direct {v0, p1}, Lz1/a;-><init>(Ljava/io/InputStream;)V

    const/4 p1, 0x0

    iput-object p1, p0, Lc2/a;->y:Ljava/util/Map;

    :cond_e
    :goto_e
    invoke-virtual {v0}, Lz1/a;->next()I

    move-result p1

    const/4 v1, -0x1

    if-le p1, v1, :cond_88

    const/4 v1, 0x0

    if-nez p1, :cond_24

    iget-object p1, p0, Lc2/a;->w:Lc2/a$a;

    .line 1
    iput v1, p1, Lc2/a$a;->b:I

    .line 2
    new-instance p1, Lorg/xml/sax/helpers/LocatorImpl;

    invoke-direct {p1}, Lorg/xml/sax/helpers/LocatorImpl;-><init>()V

    .line 3
    iput-object p1, p0, Lv2/e;->t:Lorg/xml/sax/Locator;

    goto :goto_e

    :cond_24
    const/4 v2, 0x1

    if-ne v2, p1, :cond_2f

    .line 4
    iget-object p1, p0, Lc2/a;->w:Lc2/a$a;

    .line 5
    iput v1, p1, Lc2/a$a;->b:I

    .line 6
    invoke-virtual {p0}, Lorg/xml/sax/helpers/DefaultHandler;->endDocument()V

    goto :goto_88

    :cond_2f
    const/4 v3, 0x2

    if-ne v3, p1, :cond_36

    invoke-virtual {p0, v0}, Lc2/a;->e(Lorg/xmlpull/v1/XmlPullParser;)V

    goto :goto_e

    :cond_36
    const/4 v3, 0x3

    if-ne v3, p1, :cond_67

    .line 7
    invoke-virtual {v0}, Lz1/a;->getName()Ljava/lang/String;

    move-result-object p1

    iget-object v3, p0, Lc2/a;->w:Lc2/a$a;

    .line 8
    iget v4, v3, Lc2/a$a;->b:I

    if-lez v4, :cond_55

    iget-object v5, v3, Lc2/a$a;->a:[Ljava/lang/String;

    add-int/lit8 v4, v4, -0x1

    aget-object v4, v5, v4

    invoke-virtual {p1, v4}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v4

    if-eqz v4, :cond_55

    iget v4, v3, Lc2/a$a;->b:I

    sub-int/2addr v4, v2

    iput v4, v3, Lc2/a$a;->b:I

    goto :goto_5d

    :cond_55
    iget v4, v3, Lc2/a$a;->b:I

    iget-object v3, v3, Lc2/a$a;->a:[Ljava/lang/String;

    array-length v3, v3

    if-ne v4, v3, :cond_5d

    move v1, v2

    :cond_5d
    :goto_5d
    if-eqz v1, :cond_e

    .line 9
    invoke-virtual {v0}, Lz1/a;->getNamespace()Ljava/lang/String;

    move-result-object v1

    invoke-virtual {p0, v1, p1, p1}, Lv2/e;->endElement(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V

    goto :goto_e

    :cond_67
    const/4 v3, 0x4

    if-ne v3, p1, :cond_e

    .line 10
    iget-object p1, p0, Lc2/a;->w:Lc2/a$a;

    .line 11
    iget v3, p1, Lc2/a$a;->b:I

    iget-object p1, p1, Lc2/a$a;->a:[Ljava/lang/String;

    array-length p1, p1

    if-ne v3, p1, :cond_75

    move p1, v2

    goto :goto_76

    :cond_75
    move p1, v1

    :goto_76
    if-eqz p1, :cond_e

    .line 12
    iget-object p1, p0, Lc2/a;->v:[I

    invoke-virtual {v0, p1}, Lz1/a;->getTextCharacters([I)[C

    move-result-object p1

    iget-object v3, p0, Lc2/a;->v:[I

    aget v1, v3, v1

    aget v2, v3, v2

    invoke-virtual {p0, p1, v1, v2}, Lv2/e;->characters([CII)V

    goto :goto_e

    .line 13
    :cond_88
    :goto_88
    iget-object p1, p0, Lv2/e;->s:Ljava/util/List;
    :try_end_8a
    .catch Ljava/lang/Exception; {:try_start_6 .. :try_end_8a} :catch_8b

    return-object p1

    :catch_8b
    move-exception p1

    .line 14
    invoke-virtual {p1}, Ljava/lang/Exception;->getMessage()Ljava/lang/String;

    move-result-object v0

    .line 15
    iget-object v1, p0, Lv2/e;->r:Lc3/d;

    invoke-virtual {v1, v0, p1}, Lc3/d;->g(Ljava/lang/String;Ljava/lang/Throwable;)V

    .line 16
    new-instance v0, Lw2/k;

    const-string v1, "Can\'t parse Android XML resource"

    invoke-direct {v0, v1, p1}, Lw2/k;-><init>(Ljava/lang/String;Ljava/lang/Throwable;)V

    throw v0

    :cond_9d
    new-instance p1, Ljava/lang/IllegalArgumentException;

    const-string v0, "Input source must specify an input stream"

    invoke-direct {p1, v0}, Ljava/lang/IllegalArgumentException;-><init>(Ljava/lang/String;)V

    throw p1
.end method

.method public final e(Lorg/xmlpull/v1/XmlPullParser;)V
    .registers 15

    check-cast p1, Lz1/a;

    invoke-virtual {p1}, Lz1/a;->getName()Ljava/lang/String;

    move-result-object v0

    iget-object v1, p0, Lc2/a;->w:Lc2/a$a;

    .line 1
    iget v2, v1, Lc2/a$a;->b:I

    iget-object v3, v1, Lc2/a$a;->a:[Ljava/lang/String;

    array-length v4, v3

    const/4 v5, 0x1

    const/4 v6, 0x0

    if-ne v2, v4, :cond_12

    goto :goto_20

    :cond_12
    aget-object v2, v3, v2

    invoke-virtual {v0, v2}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v2

    if-eqz v2, :cond_1f

    iget v2, v1, Lc2/a$a;->b:I

    add-int/2addr v2, v5

    iput v2, v1, Lc2/a$a;->b:I

    :cond_1f
    move v5, v6

    :goto_20
    if-eqz v5, :cond_4e

    .line 2
    new-instance v1, Lorg/xml/sax/helpers/AttributesImpl;

    invoke-direct {v1}, Lorg/xml/sax/helpers/AttributesImpl;-><init>()V

    move v2, v6

    :goto_28
    invoke-virtual {p1}, Lz1/a;->getAttributeCount()I

    move-result v3

    if-ge v2, v3, :cond_47

    invoke-virtual {p1, v2}, Lz1/a;->getAttributeNamespace(I)Ljava/lang/String;

    move-result-object v8

    invoke-virtual {p1, v2}, Lz1/a;->getAttributeName(I)Ljava/lang/String;

    move-result-object v9

    invoke-virtual {p1, v2}, Lz1/a;->getAttributeName(I)Ljava/lang/String;

    move-result-object v10

    invoke-virtual {p1, v2}, Lz1/a;->getAttributeValue(I)Ljava/lang/String;

    move-result-object v12

    const-string v11, "CDATA"

    move-object v7, v1

    invoke-virtual/range {v7 .. v12}, Lorg/xml/sax/helpers/AttributesImpl;->addAttribute(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V

    add-int/lit8 v2, v2, 0x1

    goto :goto_28

    :cond_47
    invoke-virtual {p1}, Lz1/a;->getNamespace()Ljava/lang/String;

    move-result-object v2

    invoke-virtual {p0, v2, v0, v0, v1}, Lv2/e;->startElement(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Lorg/xml/sax/Attributes;)V

    .line 3
    :cond_4e
    iget-object v0, p0, Lc2/a;->x:Ljava/lang/String;

    if-eqz v0, :cond_b0

    iget-object v0, p0, Lc2/a;->y:Ljava/util/Map;

    if-nez v0, :cond_b0

    invoke-virtual {p1}, Lz1/a;->getName()Ljava/lang/String;

    move-result-object v0

    iget-object v1, p0, Lc2/a;->x:Ljava/lang/String;

    invoke-virtual {v0, v1}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v0

    if-eqz v0, :cond_b0

    new-instance v0, Ljava/util/HashMap;

    invoke-direct {v0}, Ljava/util/HashMap;-><init>()V

    :goto_67
    invoke-virtual {p1}, Lz1/a;->getAttributeCount()I

    move-result v1

    if-ge v6, v1, :cond_ae

    invoke-virtual {p1, v6}, Lz1/a;->getAttributeNamespace(I)Ljava/lang/String;

    move-result-object v1

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

    move-result v2

    if-lez v2, :cond_93

    const-string v2, "/"

    invoke-virtual {v1, v2}, Ljava/lang/String;->lastIndexOf(Ljava/lang/String;)I

    move-result v2

    const/4 v3, -0x1

    if-le v2, v3, :cond_8c

    add-int/lit8 v2, v2, 0x1

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

    move-result v3

    if-ge v2, v3, :cond_8c

    invoke-virtual {v1, v2}, Ljava/lang/String;->substring(I)Ljava/lang/String;

    move-result-object v1

    :cond_8c
    const-string v2, ":"

    invoke-static {v1, v2}, Le/a;->a(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;

    move-result-object v1

    goto :goto_95

    :cond_93
    const-string v1, ""

    :goto_95
    invoke-static {v1}, Landroidx/activity/c;->a(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v1

    invoke-virtual {p1, v6}, Lz1/a;->getAttributeName(I)Ljava/lang/String;

    move-result-object v2

    invoke-virtual {v1, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v1

    invoke-virtual {p1, v6}, Lz1/a;->getAttributeValue(I)Ljava/lang/String;

    move-result-object v2

    invoke-virtual {v0, v1, v2}, Ljava/util/HashMap;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;

    add-int/lit8 v6, v6, 0x1

    goto :goto_67

    :cond_ae
    iput-object v0, p0, Lc2/a;->y:Ljava/util/Map;

    :cond_b0
    return-void
.end method
