.class public Lcom/glu/plugins/gluanalytics/util/Conversion; .super Ljava/lang/Object; .source "SourceFile" # static fields .field private static final HUNDRED_AS_DECIMAL:Ljava/math/BigDecimal; # direct methods .method static constructor ()V .locals 2 .line 6 new-instance v0, Ljava/math/BigDecimal; const/16 v1, 0x64 invoke-direct {v0, v1}, Ljava/math/BigDecimal;->(I)V sput-object v0, Lcom/glu/plugins/gluanalytics/util/Conversion;->HUNDRED_AS_DECIMAL:Ljava/math/BigDecimal; return-void .end method .method public constructor ()V .locals 0 .line 5 invoke-direct {p0}, Ljava/lang/Object;->()V return-void .end method .method public static centsToUsd(J)D .locals 2 long-to-double p0, p0 const-wide v0, 0x3f847ae147ae147bL # 0.01 mul-double/2addr p0, v0 return-wide p0 .end method .method public static usdToCents(D)J .locals 2 const-wide/high16 v0, 0x4059000000000000L # 100.0 mul-double/2addr p0, v0 const-wide/high16 v0, 0x3fe0000000000000L # 0.5 add-double/2addr p0, v0 double-to-long p0, p0 return-wide p0 .end method .method public static usdToCentsInDecimal(D)Ljava/math/BigDecimal; .locals 0 .line 17 invoke-static {p0, p1}, Ljava/math/BigDecimal;->valueOf(D)Ljava/math/BigDecimal; move-result-object p0 sget-object p1, Lcom/glu/plugins/gluanalytics/util/Conversion;->HUNDRED_AS_DECIMAL:Ljava/math/BigDecimal; invoke-virtual {p0, p1}, Ljava/math/BigDecimal;->multiply(Ljava/math/BigDecimal;)Ljava/math/BigDecimal; move-result-object p0 return-object p0 .end method