StringRequest.smali

.class public Lcom/tradplus/ads/volley/toolbox/StringRequest;
.super Lcom/tradplus/ads/volley/Request;


# annotations
.annotation system Ldalvik/annotation/Signature;
    value = {
        "Lcom/tradplus/ads/volley/Request<",
        "Ljava/lang/String;",
        ">;"
    }
.end annotation


# instance fields
.field private final a:Lcom/tradplus/ads/volley/Response$Listener;
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "Lcom/tradplus/ads/volley/Response$Listener<",
            "Ljava/lang/String;",
            ">;"
        }
    .end annotation
.end field


# direct methods
.method public constructor <init>(ILjava/lang/String;Lcom/tradplus/ads/volley/Response$Listener;Lcom/tradplus/ads/volley/Response$ErrorListener;)V
    .registers 5
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "(I",
            "Ljava/lang/String;",
            "Lcom/tradplus/ads/volley/Response$Listener<",
            "Ljava/lang/String;",
            ">;",
            "Lcom/tradplus/ads/volley/Response$ErrorListener;",
            ")V"
        }
    .end annotation

    invoke-direct {p0, p1, p2, p4}, Lcom/tradplus/ads/volley/Request;-><init>(ILjava/lang/String;Lcom/tradplus/ads/volley/Response$ErrorListener;)V

    iput-object p3, p0, Lcom/tradplus/ads/volley/toolbox/StringRequest;->a:Lcom/tradplus/ads/volley/Response$Listener;

    return-void
.end method

.method public constructor <init>(Ljava/lang/String;Lcom/tradplus/ads/volley/Response$Listener;Lcom/tradplus/ads/volley/Response$ErrorListener;)V
    .registers 5
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "(",
            "Ljava/lang/String;",
            "Lcom/tradplus/ads/volley/Response$Listener<",
            "Ljava/lang/String;",
            ">;",
            "Lcom/tradplus/ads/volley/Response$ErrorListener;",
            ")V"
        }
    .end annotation

    const/4 v0, 0x0

    invoke-direct {p0, v0, p1, p2, p3}, Lcom/tradplus/ads/volley/toolbox/StringRequest;-><init>(ILjava/lang/String;Lcom/tradplus/ads/volley/Response$Listener;Lcom/tradplus/ads/volley/Response$ErrorListener;)V

    return-void
.end method


# virtual methods
.method protected a(Lcom/tradplus/ads/volley/NetworkResponse;)Lcom/tradplus/ads/volley/Response;
    .registers 5
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "(",
            "Lcom/tradplus/ads/volley/NetworkResponse;",
            ")",
            "Lcom/tradplus/ads/volley/Response<",
            "Ljava/lang/String;",
            ">;"
        }
    .end annotation

    :try_start_0
    new-instance v0, Ljava/lang/String;

    iget-object v1, p1, Lcom/tradplus/ads/volley/NetworkResponse;->data:[B

    iget-object v2, p1, Lcom/tradplus/ads/volley/NetworkResponse;->headers:Ljava/util/Map;

    invoke-static {v2}, Lcom/tradplus/ads/volley/toolbox/HttpHeaderParser;->parseCharset(Ljava/util/Map;)Ljava/lang/String;

    move-result-object v2

    invoke-direct {v0, v1, v2}, Ljava/lang/String;-><init>([BLjava/lang/String;)V
    :try_end_d
    .catch Ljava/io/UnsupportedEncodingException; {:try_start_0 .. :try_end_d} :catch_e

    goto :goto_15

    :catch_e
    new-instance v0, Ljava/lang/String;

    iget-object v1, p1, Lcom/tradplus/ads/volley/NetworkResponse;->data:[B

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

    :goto_15
    invoke-static {p1}, Lcom/tradplus/ads/volley/toolbox/HttpHeaderParser;->parseCacheHeaders(Lcom/tradplus/ads/volley/NetworkResponse;)Lcom/tradplus/ads/volley/Cache$Entry;

    move-result-object p1

    invoke-static {v0, p1}, Lcom/tradplus/ads/volley/Response;->success(Ljava/lang/Object;Lcom/tradplus/ads/volley/Cache$Entry;)Lcom/tradplus/ads/volley/Response;

    move-result-object p1

    return-object p1
.end method

.method protected b(Ljava/lang/String;)V
    .registers 3

    iget-object v0, p0, Lcom/tradplus/ads/volley/toolbox/StringRequest;->a:Lcom/tradplus/ads/volley/Response$Listener;

    invoke-interface {v0, p1}, Lcom/tradplus/ads/volley/Response$Listener;->onResponse(Ljava/lang/Object;)V

    return-void
.end method

.method protected synthetic deliverResponse(Ljava/lang/Object;)V
    .registers 2

    check-cast p1, Ljava/lang/String;

    invoke-virtual {p0, p1}, Lcom/tradplus/ads/volley/toolbox/StringRequest;->b(Ljava/lang/String;)V

    return-void
.end method