.class Lcom/amap/api/services/a/av$4;
.super Ljava/lang/Thread;
.source "RouteSearchCore.java"


# annotations
.annotation system Ldalvik/annotation/EnclosingMethod;
    value = Lcom/amap/api/services/a/av;->calculateRideRouteAsyn(Lcom/amap/api/services/route/RouteSearch$RideRouteQuery;)V
.end annotation

.annotation system Ldalvik/annotation/InnerClass;
    accessFlags = 0x0
    name = null
.end annotation


# instance fields
.field final synthetic a:Lcom/amap/api/services/route/RouteSearch$RideRouteQuery;

.field final synthetic b:Lcom/amap/api/services/a/av;


# direct methods
.method constructor <init>(Lcom/amap/api/services/a/av;Lcom/amap/api/services/route/RouteSearch$RideRouteQuery;)V
    .locals 0

    .line 262
    iput-object p1, p0, Lcom/amap/api/services/a/av$4;->b:Lcom/amap/api/services/a/av;

    iput-object p2, p0, Lcom/amap/api/services/a/av$4;->a:Lcom/amap/api/services/route/RouteSearch$RideRouteQuery;

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

    return-void
.end method


# virtual methods
.method public run()V
    .locals 6

    .line 265
    invoke-static {}, Lcom/amap/api/services/a/r;->a()Lcom/amap/api/services/a/r;

    move-result-object v0

    invoke-virtual {v0}, Lcom/amap/api/services/a/r;->obtainMessage()Landroid/os/Message;

    move-result-object v0

    const/16 v1, 0x67

    .line 266
    iput v1, v0, Landroid/os/Message;->what:I

    const/4 v1, 0x1

    .line 267
    iput v1, v0, Landroid/os/Message;->arg1:I

    .line 268
    new-instance v1, Landroid/os/Bundle;

    invoke-direct {v1}, Landroid/os/Bundle;-><init>()V

    const/4 v2, 0x0

    .line 271
    :try_start_0
    iget-object v3, p0, Lcom/amap/api/services/a/av$4;->b:Lcom/amap/api/services/a/av;

    iget-object v4, p0, Lcom/amap/api/services/a/av$4;->a:Lcom/amap/api/services/route/RouteSearch$RideRouteQuery;

    invoke-virtual {v3, v4}, Lcom/amap/api/services/a/av;->calculateRideRoute(Lcom/amap/api/services/route/RouteSearch$RideRouteQuery;)Lcom/amap/api/services/route/RideRouteResult;

    move-result-object v3
    :try_end_0
    .catch Lcom/amap/api/services/core/AMapException; {:try_start_0 .. :try_end_0} :catch_1
    .catchall {:try_start_0 .. :try_end_0} :catchall_1

    :try_start_1
    const-string v2, "errorCode"

    const/16 v4, 0x3e8

    .line 272
    invoke-virtual {v1, v2, v4}, Landroid/os/Bundle;->putInt(Ljava/lang/String;I)V
    :try_end_1
    .catch Lcom/amap/api/services/core/AMapException; {:try_start_1 .. :try_end_1} :catch_0
    .catchall {:try_start_1 .. :try_end_1} :catchall_0

    .line 276
    iget-object v2, p0, Lcom/amap/api/services/a/av$4;->b:Lcom/amap/api/services/a/av;

    invoke-static {v2}, Lcom/amap/api/services/a/av;->a(Lcom/amap/api/services/a/av;)Lcom/amap/api/services/route/RouteSearch$OnRouteSearchListener;

    move-result-object v2

    iput-object v2, v0, Landroid/os/Message;->obj:Ljava/lang/Object;

    const-string v2, "result"

    .line 277
    invoke-virtual {v1, v2, v3}, Landroid/os/Bundle;->putParcelable(Ljava/lang/String;Landroid/os/Parcelable;)V

    goto :goto_1

    :catchall_0
    move-exception v2

    move-object v5, v3

    move-object v3, v2

    move-object v2, v5

    goto :goto_2

    :catch_0
    move-exception v2

    move-object v5, v3

    move-object v3, v2

    move-object v2, v5

    goto :goto_0

    :catchall_1
    move-exception v3

    goto :goto_2

    :catch_1
    move-exception v3

    :goto_0
    :try_start_2
    const-string v4, "errorCode"

    .line 274
    invoke-virtual {v3}, Lcom/amap/api/services/core/AMapException;->getErrorCode()I

    move-result v3

    invoke-virtual {v1, v4, v3}, Landroid/os/Bundle;->putInt(Ljava/lang/String;I)V
    :try_end_2
    .catchall {:try_start_2 .. :try_end_2} :catchall_1

    .line 276
    iget-object v3, p0, Lcom/amap/api/services/a/av$4;->b:Lcom/amap/api/services/a/av;

    invoke-static {v3}, Lcom/amap/api/services/a/av;->a(Lcom/amap/api/services/a/av;)Lcom/amap/api/services/route/RouteSearch$OnRouteSearchListener;

    move-result-object v3

    iput-object v3, v0, Landroid/os/Message;->obj:Ljava/lang/Object;

    const-string v3, "result"

    .line 277
    invoke-virtual {v1, v3, v2}, Landroid/os/Bundle;->putParcelable(Ljava/lang/String;Landroid/os/Parcelable;)V

    .line 278
    :goto_1
    invoke-virtual {v0, v1}, Landroid/os/Message;->setData(Landroid/os/Bundle;)V

    .line 279
    iget-object v1, p0, Lcom/amap/api/services/a/av$4;->b:Lcom/amap/api/services/a/av;

    invoke-static {v1}, Lcom/amap/api/services/a/av;->b(Lcom/amap/api/services/a/av;)Landroid/os/Handler;

    move-result-object v1

    invoke-virtual {v1, v0}, Landroid/os/Handler;->sendMessage(Landroid/os/Message;)Z

    return-void

    .line 276
    :goto_2
    iget-object v4, p0, Lcom/amap/api/services/a/av$4;->b:Lcom/amap/api/services/a/av;

    invoke-static {v4}, Lcom/amap/api/services/a/av;->a(Lcom/amap/api/services/a/av;)Lcom/amap/api/services/route/RouteSearch$OnRouteSearchListener;

    move-result-object v4

    iput-object v4, v0, Landroid/os/Message;->obj:Ljava/lang/Object;

    const-string v4, "result"

    .line 277
    invoke-virtual {v1, v4, v2}, Landroid/os/Bundle;->putParcelable(Ljava/lang/String;Landroid/os/Parcelable;)V

    .line 278
    invoke-virtual {v0, v1}, Landroid/os/Message;->setData(Landroid/os/Bundle;)V

    .line 279
    iget-object v1, p0, Lcom/amap/api/services/a/av$4;->b:Lcom/amap/api/services/a/av;

    invoke-static {v1}, Lcom/amap/api/services/a/av;->b(Lcom/amap/api/services/a/av;)Landroid/os/Handler;

    move-result-object v1

    invoke-virtual {v1, v0}, Landroid/os/Handler;->sendMessage(Landroid/os/Message;)Z

    throw v3
.end method
