LocationResult.smali
.class public final Lcom/google/android/gms/location/LocationResult;
.super Lcom/google/android/gms/common/internal/safeparcel/AbstractSafeParcelable;
# interfaces
.implements Lcom/google/android/gms/common/internal/ReflectedParcelable;
# static fields
.field public static final CREATOR:Landroid/os/Parcelable$Creator;
.annotation system Ldalvik/annotation/Signature;
value = {
"Landroid/os/Parcelable$Creator<",
"Lcom/google/android/gms/location/LocationResult;",
">;"
}
.end annotation
.end field
.field static final zzbb:Ljava/util/List;
.annotation system Ldalvik/annotation/Signature;
value = {
"Ljava/util/List<",
"Landroid/location/Location;",
">;"
}
.end annotation
.end field
# instance fields
.field private final zzbc:Ljava/util/List;
.annotation system Ldalvik/annotation/Signature;
value = {
"Ljava/util/List<",
"Landroid/location/Location;",
">;"
}
.end annotation
.end field
# direct methods
.method static constructor <clinit>()V
.registers 1
invoke-static {}, Ljava/util/Collections;->emptyList()Ljava/util/List;
move-result-object v0
sput-object v0, Lcom/google/android/gms/location/LocationResult;->zzbb:Ljava/util/List;
new-instance v0, Lcom/google/android/gms/location/zzac;
invoke-direct {v0}, Lcom/google/android/gms/location/zzac;-><init>()V
sput-object v0, Lcom/google/android/gms/location/LocationResult;->CREATOR:Landroid/os/Parcelable$Creator;
return-void
.end method
.method constructor <init>(Ljava/util/List;)V
.registers 2
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Ljava/util/List<",
"Landroid/location/Location;",
">;)V"
}
.end annotation
invoke-direct {p0}, Lcom/google/android/gms/common/internal/safeparcel/AbstractSafeParcelable;-><init>()V
iput-object p1, p0, Lcom/google/android/gms/location/LocationResult;->zzbc:Ljava/util/List;
return-void
.end method
.method public static create(Ljava/util/List;)Lcom/google/android/gms/location/LocationResult;
.registers 2
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Ljava/util/List<",
"Landroid/location/Location;",
">;)",
"Lcom/google/android/gms/location/LocationResult;"
}
.end annotation
if-nez p0, :cond_4
sget-object p0, Lcom/google/android/gms/location/LocationResult;->zzbb:Ljava/util/List;
:cond_4
new-instance v0, Lcom/google/android/gms/location/LocationResult;
invoke-direct {v0, p0}, Lcom/google/android/gms/location/LocationResult;-><init>(Ljava/util/List;)V
return-object v0
.end method
.method public static extractResult(Landroid/content/Intent;)Lcom/google/android/gms/location/LocationResult;
.registers 2
invoke-static {p0}, Lcom/google/android/gms/location/LocationResult;->hasResult(Landroid/content/Intent;)Z
move-result v0
if-nez v0, :cond_8
const/4 p0, 0x0
return-object p0
:cond_8
invoke-virtual {p0}, Landroid/content/Intent;->getExtras()Landroid/os/Bundle;
move-result-object p0
const-string v0, "com.google.android.gms.location.EXTRA_LOCATION_RESULT"
invoke-virtual {p0, v0}, Landroid/os/Bundle;->getParcelable(Ljava/lang/String;)Landroid/os/Parcelable;
move-result-object p0
check-cast p0, Lcom/google/android/gms/location/LocationResult;
return-object p0
.end method
.method public static hasResult(Landroid/content/Intent;)Z
.registers 2
if-nez p0, :cond_4
const/4 p0, 0x0
return p0
:cond_4
const-string v0, "com.google.android.gms.location.EXTRA_LOCATION_RESULT"
invoke-virtual {p0, v0}, Landroid/content/Intent;->hasExtra(Ljava/lang/String;)Z
move-result p0
return p0
.end method
# virtual methods
.method public final equals(Ljava/lang/Object;)Z
.registers 9
instance-of v0, p1, Lcom/google/android/gms/location/LocationResult;
const/4 v1, 0x0
if-nez v0, :cond_6
return v1
:cond_6
check-cast p1, Lcom/google/android/gms/location/LocationResult;
iget-object v0, p1, Lcom/google/android/gms/location/LocationResult;->zzbc:Ljava/util/List;
invoke-interface {v0}, Ljava/util/List;->size()I
move-result v0
iget-object v2, p0, Lcom/google/android/gms/location/LocationResult;->zzbc:Ljava/util/List;
invoke-interface {v2}, Ljava/util/List;->size()I
move-result v2
if-eq v0, v2, :cond_17
return v1
:cond_17
iget-object p1, p1, Lcom/google/android/gms/location/LocationResult;->zzbc:Ljava/util/List;
invoke-interface {p1}, Ljava/util/List;->iterator()Ljava/util/Iterator;
move-result-object p1
iget-object v0, p0, Lcom/google/android/gms/location/LocationResult;->zzbc:Ljava/util/List;
invoke-interface {v0}, Ljava/util/List;->iterator()Ljava/util/Iterator;
move-result-object v0
:cond_23
invoke-interface {p1}, Ljava/util/Iterator;->hasNext()Z
move-result v2
if-eqz v2, :cond_42
invoke-interface {v0}, Ljava/util/Iterator;->next()Ljava/lang/Object;
move-result-object v2
check-cast v2, Landroid/location/Location;
invoke-interface {p1}, Ljava/util/Iterator;->next()Ljava/lang/Object;
move-result-object v3
check-cast v3, Landroid/location/Location;
invoke-virtual {v2}, Landroid/location/Location;->getTime()J
move-result-wide v4
invoke-virtual {v3}, Landroid/location/Location;->getTime()J
move-result-wide v2
cmp-long v6, v4, v2
if-eqz v6, :cond_23
return v1
:cond_42
const/4 p1, 0x1
return p1
.end method
.method public final getLastLocation()Landroid/location/Location;
.registers 3
iget-object v0, p0, Lcom/google/android/gms/location/LocationResult;->zzbc:Ljava/util/List;
invoke-interface {v0}, Ljava/util/List;->size()I
move-result v0
if-nez v0, :cond_a
const/4 v0, 0x0
return-object v0
:cond_a
iget-object v1, p0, Lcom/google/android/gms/location/LocationResult;->zzbc:Ljava/util/List;
add-int/lit8 v0, v0, -0x1
invoke-interface {v1, v0}, Ljava/util/List;->get(I)Ljava/lang/Object;
move-result-object v0
check-cast v0, Landroid/location/Location;
return-object v0
.end method
.method public final getLocations()Ljava/util/List;
.registers 2
.annotation system Ldalvik/annotation/Signature;
value = {
"()",
"Ljava/util/List<",
"Landroid/location/Location;",
">;"
}
.end annotation
iget-object v0, p0, Lcom/google/android/gms/location/LocationResult;->zzbc:Ljava/util/List;
return-object v0
.end method
.method public final hashCode()I
.registers 7
iget-object v0, p0, Lcom/google/android/gms/location/LocationResult;->zzbc:Ljava/util/List;
invoke-interface {v0}, Ljava/util/List;->iterator()Ljava/util/Iterator;
move-result-object v0
const/16 v1, 0x11
:goto_8
invoke-interface {v0}, Ljava/util/Iterator;->hasNext()Z
move-result v2
if-eqz v2, :cond_22
invoke-interface {v0}, Ljava/util/Iterator;->next()Ljava/lang/Object;
move-result-object v2
check-cast v2, Landroid/location/Location;
invoke-virtual {v2}, Landroid/location/Location;->getTime()J
move-result-wide v2
const/16 v4, 0x20
ushr-long v4, v2, v4
xor-long/2addr v2, v4
long-to-int v3, v2
mul-int/lit8 v1, v1, 0x1f
add-int/2addr v1, v3
goto :goto_8
:cond_22
return v1
.end method
.method public final toString()Ljava/lang/String;
.registers 4
iget-object v0, p0, Lcom/google/android/gms/location/LocationResult;->zzbc:Ljava/util/List;
invoke-static {v0}, Ljava/lang/String;->valueOf(Ljava/lang/Object;)Ljava/lang/String;
move-result-object v0
invoke-static {v0}, Ljava/lang/String;->valueOf(Ljava/lang/Object;)Ljava/lang/String;
move-result-object v1
invoke-virtual {v1}, Ljava/lang/String;->length()I
move-result v1
add-int/lit8 v1, v1, 0x1b
new-instance v2, Ljava/lang/StringBuilder;
invoke-direct {v2, v1}, Ljava/lang/StringBuilder;-><init>(I)V
const-string v1, "LocationResult[locations: "
invoke-virtual {v2, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
invoke-virtual {v2, v0}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
const-string v0, "]"
invoke-virtual {v2, v0}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
invoke-virtual {v2}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
move-result-object v0
return-object v0
.end method
.method public final writeToParcel(Landroid/os/Parcel;I)V
.registers 6
invoke-static {p1}, Lcom/google/android/gms/common/internal/safeparcel/SafeParcelWriter;->beginObjectHeader(Landroid/os/Parcel;)I
move-result p2
invoke-virtual {p0}, Lcom/google/android/gms/location/LocationResult;->getLocations()Ljava/util/List;
move-result-object v0
const/4 v1, 0x1
const/4 v2, 0x0
invoke-static {p1, v1, v0, v2}, Lcom/google/android/gms/common/internal/safeparcel/SafeParcelWriter;->writeTypedList(Landroid/os/Parcel;ILjava/util/List;Z)V
invoke-static {p1, p2}, Lcom/google/android/gms/common/internal/safeparcel/SafeParcelWriter;->finishObjectHeader(Landroid/os/Parcel;I)V
return-void
.end method