PushSdk$Companion.smali

.class public final Lcom/demiroren/push/PushSdk$Companion;
.super Ljava/lang/Object;
.source "PushSdk.kt"


# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
    value = Lcom/demiroren/push/PushSdk;
.end annotation

.annotation system Ldalvik/annotation/InnerClass;
    accessFlags = 0x19
    name = "Companion"
.end annotation

.annotation system Ldalvik/annotation/SourceDebugExtension;
    value = "SMAP\nPushSdk.kt\nKotlin\n*S Kotlin\n*F\n+ 1 PushSdk.kt\ncom/demiroren/push/PushSdk$Companion\n*L\n1#1,271:1\n*E\n"
.end annotation

.annotation runtime Lkotlin/Metadata;
    bv = {
        0x1,
        0x0,
        0x3
    }
    d1 = {
        "\u0000`\n\u0002\u0018\u0002\n\u0002\u0010\u0000\n\u0002\u0008\u0002\n\u0002\u0010\u000e\n\u0002\u0008\u0005\n\u0002\u0018\u0002\n\u0002\u0008\u0008\n\u0002\u0018\u0002\n\u0002\u0008\u0008\n\u0002\u0018\u0002\n\u0002\u0008\u0008\n\u0002\u0010\u0002\n\u0000\n\u0002\u0010\u000b\n\u0002\u0008\u0002\n\u0002\u0018\u0002\n\u0002\u0008\u0002\n\u0002\u0018\u0002\n\u0002\u0008\u000b\n\u0002\u0010!\n\u0000\n\u0002\u0010$\n\u0002\u0008\u0002\n\u0002\u0018\u0002\n\u0002\u0008\u0007\u0008\u0086\u0003\u0018\u00002\u00020\u0001B\u0007\u0008\u0002\u00a2\u0006\u0002\u0010\u0002J\u0010\u0010$\u001a\u00020%2\u0006\u0010&\u001a\u00020\'H\u0002J\u0012\u0010(\u001a\u0004\u0018\u00010\u00042\u0006\u0010)\u001a\u00020*H\u0002J\u001a\u0010+\u001a\u00020%2\u0008\u0010!\u001a\u0004\u0018\u00010\u00042\u0006\u0010,\u001a\u00020-H\u0007J0\u0010.\u001a\u00020%2\u0006\u0010/\u001a\u00020\u00042\u0006\u00100\u001a\u00020\u00042\u0006\u00101\u001a\u00020\u00042\u0006\u00102\u001a\u00020\u00132\u0006\u0010&\u001a\u00020\'H\u0007J\u001c\u00103\u001a\u00020%2\u0008\u00104\u001a\u0004\u0018\u00010\u00042\u0008\u0010!\u001a\u0004\u0018\u00010\u0004H\u0007J\u001c\u00105\u001a\u00020%2\u0008\u00104\u001a\u0004\u0018\u00010\u00042\u0008\u0010!\u001a\u0004\u0018\u00010\u0004H\u0007JQ\u00106\u001a\u00020%2\u0008\u00107\u001a\u0004\u0018\u00010\u00042\u000e\u00108\u001a\n\u0012\u0004\u0012\u00020\u0004\u0018\u0001092\u0014\u0010:\u001a\u0010\u0012\u0004\u0012\u00020\u0004\u0012\u0004\u0012\u00020\u0004\u0018\u00010;2\u0008\u0010<\u001a\u0004\u0018\u00010\'2\u0008\u0010=\u001a\u0004\u0018\u00010>H\u0007\u00a2\u0006\u0002\u0010?JQ\u0010@\u001a\u00020%2\u000e\u0010A\u001a\n\u0012\u0004\u0012\u00020\u0004\u0018\u0001092\u0008\u00107\u001a\u0004\u0018\u00010\u00042\u0008\u0010B\u001a\u0004\u0018\u00010\u00042\u0008\u0010C\u001a\u0004\u0018\u00010\'2\u0014\u0010:\u001a\u0010\u0012\u0004\u0012\u00020\u0004\u0012\u0004\u0012\u00020\u0004\u0018\u00010;H\u0007\u00a2\u0006\u0002\u0010DR\u001a\u0010\u0003\u001a\u00020\u0004X\u0086.\u00a2\u0006\u000e\n\u0000\u001a\u0004\u0008\u0005\u0010\u0006\"\u0004\u0008\u0007\u0010\u0008R\u001c\u0010\t\u001a\u0004\u0018\u00010\nX\u0086\u000e\u00a2\u0006\u000e\n\u0000\u001a\u0004\u0008\u000b\u0010\u000c\"\u0004\u0008\r\u0010\u000eR\u001a\u0010\u000f\u001a\u00020\u0004X\u0086.\u00a2\u0006\u000e\n\u0000\u001a\u0004\u0008\u0010\u0010\u0006\"\u0004\u0008\u0011\u0010\u0008R\u001c\u0010\u0012\u001a\u0004\u0018\u00010\u0013X\u0086\u000e\u00a2\u0006\u000e\n\u0000\u001a\u0004\u0008\u0014\u0010\u0015\"\u0004\u0008\u0016\u0010\u0017R\u001a\u0010\u0018\u001a\u00020\u0004X\u0086.\u00a2\u0006\u000e\n\u0000\u001a\u0004\u0008\u0019\u0010\u0006\"\u0004\u0008\u001a\u0010\u0008R\u001c\u0010\u001b\u001a\u0004\u0018\u00010\u001cX\u0086\u000e\u00a2\u0006\u000e\n\u0000\u001a\u0004\u0008\u001d\u0010\u001e\"\u0004\u0008\u001f\u0010 R\u001c\u0010!\u001a\u0004\u0018\u00010\u0004X\u0086\u000e\u00a2\u0006\u000e\n\u0000\u001a\u0004\u0008\"\u0010\u0006\"\u0004\u0008#\u0010\u0008\u00a8\u0006E"
    }
    d2 = {
        "Lcom/demiroren/push/PushSdk$Companion;",
        "",
        "()V",
        "BASE_URL",
        "",
        "getBASE_URL",
        "()Ljava/lang/String;",
        "setBASE_URL",
        "(Ljava/lang/String;)V",
        "apiService",
        "Lcom/demiroren/push/ApiService;",
        "getApiService",
        "()Lcom/demiroren/push/ApiService;",
        "setApiService",
        "(Lcom/demiroren/push/ApiService;)V",
        "authKey",
        "getAuthKey",
        "setAuthKey",
        "context",
        "Landroid/content/Context;",
        "getContext",
        "()Landroid/content/Context;",
        "setContext",
        "(Landroid/content/Context;)V",
        "projectId",
        "getProjectId",
        "setProjectId",
        "retrofitClient",
        "Lretrofit2/Retrofit;",
        "getRetrofitClient",
        "()Lretrofit2/Retrofit;",
        "setRetrofitClient",
        "(Lretrofit2/Retrofit;)V",
        "token",
        "getToken",
        "setToken",
        "createRetrofit",
        "",
        "isLoggingEnabled",
        "",
        "getGMTFormat",
        "timeZone",
        "Ljava/util/TimeZone;",
        "getListByExternalDeviceId",
        "notificationCallback",
        "Lcom/demiroren/push/NotificationCallback;",
        "init",
        "_projectId",
        "_baseUrl",
        "_authKey",
        "_context",
        "markAsClicked",
        "notificationId",
        "markAsReceived",
        "register",
        "_token",
        "_topics",
        "",
        "_segments",
        "",
        "_allowNotification",
        "registerCallback",
        "Lcom/demiroren/push/RegisterCallback;",
        "(Ljava/lang/String;Ljava/util/List;Ljava/util/Map;Ljava/lang/Boolean;Lcom/demiroren/push/RegisterCallback;)V",
        "updateUserData",
        "topics",
        "_externalId",
        "__allowNotification",
        "(Ljava/util/List;Ljava/lang/String;Ljava/lang/String;Ljava/lang/Boolean;Ljava/util/Map;)V",
        "demirorenpushsdk_release"
    }
    k = 0x1
    mv = {
        0x1,
        0x1,
        0xf
    }
.end annotation


# direct methods
.method private constructor <init>()V
    .registers 1

    .line 20
    invoke-direct {p0}, Ljava/lang/Object;-><init>()V

    return-void
.end method

.method public synthetic constructor <init>(Lkotlin/jvm/internal/DefaultConstructorMarker;)V
    .registers 2

    .line 20
    invoke-direct {p0}, Lcom/demiroren/push/PushSdk$Companion;-><init>()V

    return-void
.end method

.method private final createRetrofit(Z)V
    .registers 5

    .line 234
    new-instance p1, Lokhttp3/OkHttpClient$Builder;

    invoke-direct {p1}, Lokhttp3/OkHttpClient$Builder;-><init>()V

    .line 235
    sget-object v0, Lcom/demiroren/push/PushSdk$Companion$createRetrofit$1;->INSTANCE:Lcom/demiroren/push/PushSdk$Companion$createRetrofit$1;

    check-cast v0, Ljavax/net/ssl/HostnameVerifier;

    invoke-virtual {p1, v0}, Lokhttp3/OkHttpClient$Builder;->hostnameVerifier(Ljavax/net/ssl/HostnameVerifier;)Lokhttp3/OkHttpClient$Builder;

    .line 244
    sget-object v0, Lcom/demiroren/push/PushSdk$Companion$createRetrofit$2;->INSTANCE:Lcom/demiroren/push/PushSdk$Companion$createRetrofit$2;

    check-cast v0, Lokhttp3/Interceptor;

    invoke-virtual {p1, v0}, Lokhttp3/OkHttpClient$Builder;->addInterceptor(Lokhttp3/Interceptor;)Lokhttp3/OkHttpClient$Builder;

    .line 257
    move-object v0, p0

    check-cast v0, Lcom/demiroren/push/PushSdk$Companion;

    .line 253
    new-instance v1, Lretrofit2/Retrofit$Builder;

    invoke-direct {v1}, Lretrofit2/Retrofit$Builder;-><init>()V

    .line 254
    invoke-static {}, Lretrofit2/converter/gson/GsonConverterFactory;->create()Lretrofit2/converter/gson/GsonConverterFactory;

    move-result-object v2

    check-cast v2, Lretrofit2/Converter$Factory;

    invoke-virtual {v1, v2}, Lretrofit2/Retrofit$Builder;->addConverterFactory(Lretrofit2/Converter$Factory;)Lretrofit2/Retrofit$Builder;

    move-result-object v1

    .line 255
    invoke-virtual {v0}, Lcom/demiroren/push/PushSdk$Companion;->getBASE_URL()Ljava/lang/String;

    move-result-object v2

    invoke-virtual {v1, v2}, Lretrofit2/Retrofit$Builder;->baseUrl(Ljava/lang/String;)Lretrofit2/Retrofit$Builder;

    move-result-object v1

    .line 256
    invoke-virtual {p1}, Lokhttp3/OkHttpClient$Builder;->build()Lokhttp3/OkHttpClient;

    move-result-object p1

    invoke-virtual {v1, p1}, Lretrofit2/Retrofit$Builder;->client(Lokhttp3/OkHttpClient;)Lretrofit2/Retrofit$Builder;

    move-result-object p1

    .line 257
    invoke-virtual {p1}, Lretrofit2/Retrofit$Builder;->build()Lretrofit2/Retrofit;

    move-result-object p1

    invoke-virtual {v0, p1}, Lcom/demiroren/push/PushSdk$Companion;->setRetrofitClient(Lretrofit2/Retrofit;)V

    .line 259
    invoke-virtual {v0}, Lcom/demiroren/push/PushSdk$Companion;->getRetrofitClient()Lretrofit2/Retrofit;

    move-result-object p1

    if-nez p1, :cond_45

    invoke-static {}, Lkotlin/jvm/internal/Intrinsics;->throwNpe()V

    :cond_45
    const-class v1, Lcom/demiroren/push/ApiService;

    invoke-virtual {p1, v1}, Lretrofit2/Retrofit;->create(Ljava/lang/Class;)Ljava/lang/Object;

    move-result-object p1

    check-cast p1, Lcom/demiroren/push/ApiService;

    invoke-virtual {v0, p1}, Lcom/demiroren/push/PushSdk$Companion;->setApiService(Lcom/demiroren/push/ApiService;)V

    return-void
.end method

.method private final getGMTFormat(Ljava/util/TimeZone;)Ljava/lang/String;
    .registers 8

    .line 99
    invoke-static {p1}, Ljava/util/GregorianCalendar;->getInstance(Ljava/util/TimeZone;)Ljava/util/Calendar;

    move-result-object v0

    const-string v1, "calendar"

    .line 100
    invoke-static {v0, v1}, Lkotlin/jvm/internal/Intrinsics;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V

    invoke-virtual {v0}, Ljava/util/Calendar;->getTimeInMillis()J

    move-result-wide v0

    invoke-virtual {p1, v0, v1}, Ljava/util/TimeZone;->getOffset(J)I

    move-result p1

    const v0, 0x36ee80

    .line 101
    div-int v0, p1, v0

    invoke-static {v0}, Ljava/lang/Math;->abs(I)I

    move-result v0

    const v1, 0xea60

    .line 102
    div-int v1, p1, v1

    rem-int/lit8 v1, v1, 0x3c

    invoke-static {v1}, Ljava/lang/Math;->abs(I)I

    move-result v1

    .line 103
    sget-object v2, Lkotlin/jvm/internal/StringCompanionObject;->INSTANCE:Lkotlin/jvm/internal/StringCompanionObject;

    const/4 v2, 0x2

    new-array v3, v2, [Ljava/lang/Object;

    invoke-static {v0}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;

    move-result-object v0

    const/4 v4, 0x0

    aput-object v0, v3, v4

    invoke-static {v1}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;

    move-result-object v0

    const/4 v1, 0x1

    aput-object v0, v3, v1

    invoke-static {v3, v2}, Ljava/util/Arrays;->copyOf([Ljava/lang/Object;I)[Ljava/lang/Object;

    move-result-object v0

    const-string v3, "%02d:%02d"

    invoke-static {v3, v0}, Ljava/lang/String;->format(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;

    move-result-object v0

    const-string v3, "java.lang.String.format(format, *args)"

    invoke-static {v0, v3}, Lkotlin/jvm/internal/Intrinsics;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V

    if-ltz p1, :cond_4c

    const-string p1, "+"

    goto :goto_4e

    :cond_4c
    const-string p1, "-"

    .line 105
    :goto_4e
    sget-object v5, Lkotlin/jvm/internal/StringCompanionObject;->INSTANCE:Lkotlin/jvm/internal/StringCompanionObject;

    new-array v5, v2, [Ljava/lang/Object;

    aput-object p1, v5, v4

    aput-object v0, v5, v1

    invoke-static {v5, v2}, Ljava/util/Arrays;->copyOf([Ljava/lang/Object;I)[Ljava/lang/Object;

    move-result-object p1

    const-string v0, "GMT %s %s"

    invoke-static {v0, p1}, Ljava/lang/String;->format(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;

    move-result-object p1

    invoke-static {p1, v3}, Lkotlin/jvm/internal/Intrinsics;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V

    return-object p1
.end method


# virtual methods
.method public final getApiService()Lcom/demiroren/push/ApiService;
    .registers 2

    .line 28
    # getter for: Lcom/demiroren/push/PushSdk;->apiService:Lcom/demiroren/push/ApiService;
    invoke-static {}, Lcom/demiroren/push/PushSdk;->access$getApiService$cp()Lcom/demiroren/push/ApiService;

    move-result-object v0

    return-object v0
.end method

.method public final getAuthKey()Ljava/lang/String;
    .registers 3

    .line 26
    # getter for: Lcom/demiroren/push/PushSdk;->authKey:Ljava/lang/String;
    invoke-static {}, Lcom/demiroren/push/PushSdk;->access$getAuthKey$cp()Ljava/lang/String;

    move-result-object v0

    if-nez v0, :cond_b

    const-string v1, "authKey"

    invoke-static {v1}, Lkotlin/jvm/internal/Intrinsics;->throwUninitializedPropertyAccessException(Ljava/lang/String;)V

    :cond_b
    return-object v0
.end method

.method public final getBASE_URL()Ljava/lang/String;
    .registers 3

    .line 24
    # getter for: Lcom/demiroren/push/PushSdk;->BASE_URL:Ljava/lang/String;
    invoke-static {}, Lcom/demiroren/push/PushSdk;->access$getBASE_URL$cp()Ljava/lang/String;

    move-result-object v0

    if-nez v0, :cond_b

    const-string v1, "BASE_URL"

    invoke-static {v1}, Lkotlin/jvm/internal/Intrinsics;->throwUninitializedPropertyAccessException(Ljava/lang/String;)V

    :cond_b
    return-object v0
.end method

.method public final getContext()Landroid/content/Context;
    .registers 2

    .line 31
    # getter for: Lcom/demiroren/push/PushSdk;->context:Landroid/content/Context;
    invoke-static {}, Lcom/demiroren/push/PushSdk;->access$getContext$cp()Landroid/content/Context;

    move-result-object v0

    return-object v0
.end method

.method public final getListByExternalDeviceId(Ljava/lang/String;Lcom/demiroren/push/NotificationCallback;)V
    .registers 12
    .annotation runtime Lkotlin/jvm/JvmStatic;
    .end annotation

    const-string v0, "notificationCallback"

    invoke-static {p2, v0}, Lkotlin/jvm/internal/Intrinsics;->checkParameterIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V

    .line 199
    move-object v0, p0

    check-cast v0, Lcom/demiroren/push/PushSdk$Companion;

    invoke-virtual {v0}, Lcom/demiroren/push/PushSdk$Companion;->getRetrofitClient()Lretrofit2/Retrofit;

    move-result-object v1

    if-eqz v1, :cond_4e

    .line 202
    invoke-virtual {v0}, Lcom/demiroren/push/PushSdk$Companion;->getApiService()Lcom/demiroren/push/ApiService;

    move-result-object v1

    if-eqz v1, :cond_44

    if-nez p1, :cond_17

    return-void

    .line 211
    :cond_17
    invoke-virtual {v0}, Lcom/demiroren/push/PushSdk$Companion;->getContext()Landroid/content/Context;

    move-result-object v1

    if-eqz v1, :cond_22

    invoke-virtual {v1}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;

    move-result-object v1

    goto :goto_23

    :cond_22
    const/4 v1, 0x0

    :goto_23
    const-string v2, "android_id"

    invoke-static {v1, v2}, Landroid/provider/Settings$Secure;->getString(Landroid/content/ContentResolver;Ljava/lang/String;)Ljava/lang/String;

    move-result-object v5

    .line 214
    invoke-virtual {v0}, Lcom/demiroren/push/PushSdk$Companion;->getApiService()Lcom/demiroren/push/ApiService;

    move-result-object v3

    if-eqz v3, :cond_43

    const/4 v4, 0x0

    const/4 v7, 0x1

    const/4 v8, 0x0

    move-object v6, p1

    .line 213
    invoke-static/range {v3 .. v8}, Lcom/demiroren/push/ApiService$DefaultImpls;->pushList$default(Lcom/demiroren/push/ApiService;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;ILjava/lang/Object;)Lretrofit2/Call;

    move-result-object p1

    if-eqz p1, :cond_43

    .line 214
    new-instance v0, Lcom/demiroren/push/PushSdk$Companion$getListByExternalDeviceId$1;

    invoke-direct {v0, p2}, Lcom/demiroren/push/PushSdk$Companion$getListByExternalDeviceId$1;-><init>(Lcom/demiroren/push/NotificationCallback;)V

    check-cast v0, Lretrofit2/Callback;

    invoke-interface {p1, v0}, Lretrofit2/Call;->enqueue(Lretrofit2/Callback;)V

    :cond_43
    return-void

    .line 203
    :cond_44
    new-instance p1, Ljava/lang/Exception;

    const-string p2, "Api Service not Created!!"

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

    check-cast p1, Ljava/lang/Throwable;

    throw p1

    .line 200
    :cond_4e
    new-instance p1, Ljava/lang/Exception;

    const-string p2, "Retrofit cannot be Null!"

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

    check-cast p1, Ljava/lang/Throwable;

    throw p1
.end method

.method public final getProjectId()Ljava/lang/String;
    .registers 3

    .line 25
    # getter for: Lcom/demiroren/push/PushSdk;->projectId:Ljava/lang/String;
    invoke-static {}, Lcom/demiroren/push/PushSdk;->access$getProjectId$cp()Ljava/lang/String;

    move-result-object v0

    if-nez v0, :cond_b

    const-string v1, "projectId"

    invoke-static {v1}, Lkotlin/jvm/internal/Intrinsics;->throwUninitializedPropertyAccessException(Ljava/lang/String;)V

    :cond_b
    return-object v0
.end method

.method public final getRetrofitClient()Lretrofit2/Retrofit;
    .registers 2

    .line 22
    # getter for: Lcom/demiroren/push/PushSdk;->retrofitClient:Lretrofit2/Retrofit;
    invoke-static {}, Lcom/demiroren/push/PushSdk;->access$getRetrofitClient$cp()Lretrofit2/Retrofit;

    move-result-object v0

    return-object v0
.end method

.method public final getToken()Ljava/lang/String;
    .registers 2

    .line 29
    # getter for: Lcom/demiroren/push/PushSdk;->token:Ljava/lang/String;
    invoke-static {}, Lcom/demiroren/push/PushSdk;->access$getToken$cp()Ljava/lang/String;

    move-result-object v0

    return-object v0
.end method

.method public final init(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Landroid/content/Context;Z)V
    .registers 7
    .annotation runtime Lkotlin/jvm/JvmStatic;
    .end annotation

    const-string v0, "_projectId"

    invoke-static {p1, v0}, Lkotlin/jvm/internal/Intrinsics;->checkParameterIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V

    const-string v0, "_baseUrl"

    invoke-static {p2, v0}, Lkotlin/jvm/internal/Intrinsics;->checkParameterIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V

    const-string v0, "_authKey"

    invoke-static {p3, v0}, Lkotlin/jvm/internal/Intrinsics;->checkParameterIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V

    const-string v0, "_context"

    invoke-static {p4, v0}, Lkotlin/jvm/internal/Intrinsics;->checkParameterIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V

    .line 41
    move-object v0, p0

    check-cast v0, Lcom/demiroren/push/PushSdk$Companion;

    invoke-virtual {v0, p2}, Lcom/demiroren/push/PushSdk$Companion;->setBASE_URL(Ljava/lang/String;)V

    .line 42
    invoke-virtual {v0, p1}, Lcom/demiroren/push/PushSdk$Companion;->setProjectId(Ljava/lang/String;)V

    .line 43
    invoke-virtual {v0, p3}, Lcom/demiroren/push/PushSdk$Companion;->setAuthKey(Ljava/lang/String;)V

    .line 44
    invoke-virtual {v0, p4}, Lcom/demiroren/push/PushSdk$Companion;->setContext(Landroid/content/Context;)V

    .line 46
    invoke-direct {v0, p5}, Lcom/demiroren/push/PushSdk$Companion;->createRetrofit(Z)V

    return-void
.end method

.method public final markAsClicked(Ljava/lang/String;Ljava/lang/String;)V
    .registers 12
    .annotation runtime Lkotlin/jvm/JvmStatic;
    .end annotation

    .line 111
    move-object v0, p0

    check-cast v0, Lcom/demiroren/push/PushSdk$Companion;

    invoke-virtual {v0}, Lcom/demiroren/push/PushSdk$Companion;->getRetrofitClient()Lretrofit2/Retrofit;

    move-result-object v1

    if-eqz v1, :cond_3c

    .line 114
    invoke-virtual {v0}, Lcom/demiroren/push/PushSdk$Companion;->getApiService()Lcom/demiroren/push/ApiService;

    move-result-object v1

    if-eqz v1, :cond_32

    if-eqz p2, :cond_31

    if-nez p1, :cond_14

    goto :goto_31

    .line 123
    :cond_14
    invoke-virtual {v0}, Lcom/demiroren/push/PushSdk$Companion;->getApiService()Lcom/demiroren/push/ApiService;

    move-result-object v2

    if-eqz v2, :cond_31

    const/4 v3, 0x0

    const/4 v6, 0x0

    const/16 v7, 0x9

    const/4 v8, 0x0

    move-object v4, p2

    move-object v5, p1

    .line 122
    invoke-static/range {v2 .. v8}, Lcom/demiroren/push/ApiService$DefaultImpls;->markAsClicked$default(Lcom/demiroren/push/ApiService;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;ILjava/lang/Object;)Lretrofit2/Call;

    move-result-object p1

    if-eqz p1, :cond_31

    .line 123
    new-instance p2, Lcom/demiroren/push/PushSdk$Companion$markAsClicked$1;

    invoke-direct {p2}, Lcom/demiroren/push/PushSdk$Companion$markAsClicked$1;-><init>()V

    check-cast p2, Lretrofit2/Callback;

    invoke-interface {p1, p2}, Lretrofit2/Call;->enqueue(Lretrofit2/Callback;)V

    :cond_31
    :goto_31
    return-void

    .line 115
    :cond_32
    new-instance p1, Ljava/lang/Exception;

    const-string p2, "Api Service not Created!!"

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

    check-cast p1, Ljava/lang/Throwable;

    throw p1

    .line 112
    :cond_3c
    new-instance p1, Ljava/lang/Exception;

    const-string p2, "Retrofit cannot be Null!"

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

    check-cast p1, Ljava/lang/Throwable;

    throw p1
.end method

.method public final markAsReceived(Ljava/lang/String;Ljava/lang/String;)V
    .registers 12
    .annotation runtime Lkotlin/jvm/JvmStatic;
    .end annotation

    .line 131
    move-object v0, p0

    check-cast v0, Lcom/demiroren/push/PushSdk$Companion;

    invoke-virtual {v0}, Lcom/demiroren/push/PushSdk$Companion;->getRetrofitClient()Lretrofit2/Retrofit;

    move-result-object v1

    if-eqz v1, :cond_3c

    .line 134
    invoke-virtual {v0}, Lcom/demiroren/push/PushSdk$Companion;->getApiService()Lcom/demiroren/push/ApiService;

    move-result-object v1

    if-eqz v1, :cond_32

    if-eqz p2, :cond_31

    if-nez p1, :cond_14

    goto :goto_31

    .line 143
    :cond_14
    invoke-virtual {v0}, Lcom/demiroren/push/PushSdk$Companion;->getApiService()Lcom/demiroren/push/ApiService;

    move-result-object v2

    if-eqz v2, :cond_31

    const/4 v3, 0x0

    const/4 v6, 0x0

    const/16 v7, 0x9

    const/4 v8, 0x0

    move-object v4, p2

    move-object v5, p1

    .line 142
    invoke-static/range {v2 .. v8}, Lcom/demiroren/push/ApiService$DefaultImpls;->markReceived$default(Lcom/demiroren/push/ApiService;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;ILjava/lang/Object;)Lretrofit2/Call;

    move-result-object p1

    if-eqz p1, :cond_31

    .line 143
    new-instance p2, Lcom/demiroren/push/PushSdk$Companion$markAsReceived$1;

    invoke-direct {p2}, Lcom/demiroren/push/PushSdk$Companion$markAsReceived$1;-><init>()V

    check-cast p2, Lretrofit2/Callback;

    invoke-interface {p1, p2}, Lretrofit2/Call;->enqueue(Lretrofit2/Callback;)V

    :cond_31
    :goto_31
    return-void

    .line 135
    :cond_32
    new-instance p1, Ljava/lang/Exception;

    const-string p2, "Api Service not Created!!"

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

    check-cast p1, Ljava/lang/Throwable;

    throw p1

    .line 132
    :cond_3c
    new-instance p1, Ljava/lang/Exception;

    const-string p2, "Retrofit cannot be Null!"

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

    check-cast p1, Ljava/lang/Throwable;

    throw p1
.end method

.method public final register(Ljava/lang/String;Ljava/util/List;Ljava/util/Map;Ljava/lang/Boolean;Lcom/demiroren/push/RegisterCallback;)V
    .registers 19
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "(",
            "Ljava/lang/String;",
            "Ljava/util/List<",
            "Ljava/lang/String;",
            ">;",
            "Ljava/util/Map<",
            "Ljava/lang/String;",
            "Ljava/lang/String;",
            ">;",
            "Ljava/lang/Boolean;",
            "Lcom/demiroren/push/RegisterCallback;",
            ")V"
        }
    .end annotation

    .annotation runtime Lkotlin/jvm/JvmStatic;
    .end annotation

    move-object v0, p1

    .line 57
    move-object v1, p0

    check-cast v1, Lcom/demiroren/push/PushSdk$Companion;

    invoke-virtual {v1}, Lcom/demiroren/push/PushSdk$Companion;->getRetrofitClient()Lretrofit2/Retrofit;

    move-result-object v2

    if-eqz v2, :cond_7e

    invoke-virtual {v1}, Lcom/demiroren/push/PushSdk$Companion;->getApiService()Lcom/demiroren/push/ApiService;

    move-result-object v2

    if-eqz v2, :cond_7e

    .line 60
    invoke-virtual {v1}, Lcom/demiroren/push/PushSdk$Companion;->getApiService()Lcom/demiroren/push/ApiService;

    move-result-object v2

    if-eqz v2, :cond_74

    if-nez v0, :cond_19

    return-void

    .line 68
    :cond_19
    invoke-virtual {v1, p1}, Lcom/demiroren/push/PushSdk$Companion;->setToken(Ljava/lang/String;)V

    .line 72
    invoke-virtual {v1}, Lcom/demiroren/push/PushSdk$Companion;->getContext()Landroid/content/Context;

    move-result-object v0

    const/4 v2, 0x0

    if-eqz v0, :cond_28

    invoke-virtual {v0}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;

    move-result-object v0

    goto :goto_29

    :cond_28
    move-object v0, v2

    :goto_29
    const-string v3, "android_id"

    .line 71
    invoke-static {v0, v3}, Landroid/provider/Settings$Secure;->getString(Landroid/content/ContentResolver;Ljava/lang/String;)Ljava/lang/String;

    move-result-object v7

    .line 76
    invoke-static {}, Ljava/util/Calendar;->getInstance()Ljava/util/Calendar;

    move-result-object v0

    const-string v3, "calendar"

    .line 77
    invoke-static {v0, v3}, Lkotlin/jvm/internal/Intrinsics;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V

    invoke-virtual {v0}, Ljava/util/Calendar;->getTimeZone()Ljava/util/TimeZone;

    move-result-object v0

    const-string v3, "calendar.timeZone"

    invoke-static {v0, v3}, Lkotlin/jvm/internal/Intrinsics;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V

    invoke-direct {v1, v0}, Lcom/demiroren/push/PushSdk$Companion;->getGMTFormat(Ljava/util/TimeZone;)Ljava/lang/String;

    move-result-object v11

    .line 79
    new-instance v0, Lcom/demiroren/push/model/RegisterRequest;

    .line 81
    invoke-virtual {v1}, Lcom/demiroren/push/PushSdk$Companion;->getToken()Ljava/lang/String;

    move-result-object v8

    const/4 v3, 0x1

    invoke-static {v3}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;

    move-result-object v9

    const-string v6, ""

    move-object v4, v0

    move-object v5, p2

    move-object/from16 v10, p4

    move-object/from16 v12, p3

    .line 79
    invoke-direct/range {v4 .. v12}, Lcom/demiroren/push/model/RegisterRequest;-><init>(Ljava/util/List;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/Integer;Ljava/lang/Boolean;Ljava/lang/String;Ljava/util/Map;)V

    .line 87
    invoke-virtual {v1}, Lcom/demiroren/push/PushSdk$Companion;->getApiService()Lcom/demiroren/push/ApiService;

    move-result-object v1

    if-eqz v1, :cond_73

    .line 84
    invoke-static {v1, v2, v0, v3, v2}, Lcom/demiroren/push/ApiService$DefaultImpls;->register$default(Lcom/demiroren/push/ApiService;Ljava/lang/String;Lcom/demiroren/push/model/RegisterRequest;ILjava/lang/Object;)Lretrofit2/Call;

    move-result-object v0

    if-eqz v0, :cond_73

    .line 87
    new-instance v1, Lcom/demiroren/push/PushSdk$Companion$register$1;

    move-object/from16 v2, p5

    invoke-direct {v1, v2}, Lcom/demiroren/push/PushSdk$Companion$register$1;-><init>(Lcom/demiroren/push/RegisterCallback;)V

    check-cast v1, Lretrofit2/Callback;

    invoke-interface {v0, v1}, Lretrofit2/Call;->enqueue(Lretrofit2/Callback;)V

    :cond_73
    return-void

    .line 61
    :cond_74
    new-instance v0, Ljava/lang/Exception;

    const-string v1, "Api Service not Created!!"

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

    check-cast v0, Ljava/lang/Throwable;

    throw v0

    .line 58
    :cond_7e
    new-instance v0, Ljava/lang/Exception;

    const-string v1, "Retrofit cannot be Null!"

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

    check-cast v0, Ljava/lang/Throwable;

    throw v0
.end method

.method public final setApiService(Lcom/demiroren/push/ApiService;)V
    .registers 2

    .line 28
    invoke-static {p1}, Lcom/demiroren/push/PushSdk;->access$setApiService$cp(Lcom/demiroren/push/ApiService;)V

    return-void
.end method

.method public final setAuthKey(Ljava/lang/String;)V
    .registers 3

    const-string v0, "<set-?>"

    invoke-static {p1, v0}, Lkotlin/jvm/internal/Intrinsics;->checkParameterIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V

    .line 26
    invoke-static {p1}, Lcom/demiroren/push/PushSdk;->access$setAuthKey$cp(Ljava/lang/String;)V

    return-void
.end method

.method public final setBASE_URL(Ljava/lang/String;)V
    .registers 3

    const-string v0, "<set-?>"

    invoke-static {p1, v0}, Lkotlin/jvm/internal/Intrinsics;->checkParameterIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V

    .line 24
    invoke-static {p1}, Lcom/demiroren/push/PushSdk;->access$setBASE_URL$cp(Ljava/lang/String;)V

    return-void
.end method

.method public final setContext(Landroid/content/Context;)V
    .registers 2

    .line 31
    invoke-static {p1}, Lcom/demiroren/push/PushSdk;->access$setContext$cp(Landroid/content/Context;)V

    return-void
.end method

.method public final setProjectId(Ljava/lang/String;)V
    .registers 3

    const-string v0, "<set-?>"

    invoke-static {p1, v0}, Lkotlin/jvm/internal/Intrinsics;->checkParameterIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V

    .line 25
    invoke-static {p1}, Lcom/demiroren/push/PushSdk;->access$setProjectId$cp(Ljava/lang/String;)V

    return-void
.end method

.method public final setRetrofitClient(Lretrofit2/Retrofit;)V
    .registers 2

    .line 22
    invoke-static {p1}, Lcom/demiroren/push/PushSdk;->access$setRetrofitClient$cp(Lretrofit2/Retrofit;)V

    return-void
.end method

.method public final setToken(Ljava/lang/String;)V
    .registers 2

    .line 29
    invoke-static {p1}, Lcom/demiroren/push/PushSdk;->access$setToken$cp(Ljava/lang/String;)V

    return-void
.end method

.method public final updateUserData(Ljava/util/List;Ljava/lang/String;Ljava/lang/String;Ljava/lang/Boolean;Ljava/util/Map;)V
    .registers 19
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "(",
            "Ljava/util/List<",
            "Ljava/lang/String;",
            ">;",
            "Ljava/lang/String;",
            "Ljava/lang/String;",
            "Ljava/lang/Boolean;",
            "Ljava/util/Map<",
            "Ljava/lang/String;",
            "Ljava/lang/String;",
            ">;)V"
        }
    .end annotation

    .annotation runtime Lkotlin/jvm/JvmStatic;
    .end annotation

    move-object v0, p2

    .line 158
    move-object v1, p0

    check-cast v1, Lcom/demiroren/push/PushSdk$Companion;

    invoke-virtual {v1}, Lcom/demiroren/push/PushSdk$Companion;->getRetrofitClient()Lretrofit2/Retrofit;

    move-result-object v2

    if-eqz v2, :cond_78

    .line 161
    invoke-virtual {v1}, Lcom/demiroren/push/PushSdk$Companion;->getApiService()Lcom/demiroren/push/ApiService;

    move-result-object v2

    if-eqz v2, :cond_6e

    if-eqz v0, :cond_6d

    if-nez p1, :cond_15

    goto :goto_6d

    .line 169
    :cond_15
    invoke-virtual {v1, p2}, Lcom/demiroren/push/PushSdk$Companion;->setToken(Ljava/lang/String;)V

    .line 171
    invoke-static {}, Ljava/util/Calendar;->getInstance()Ljava/util/Calendar;

    move-result-object v0

    const-string v2, "calendar"

    .line 172
    invoke-static {v0, v2}, Lkotlin/jvm/internal/Intrinsics;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V

    invoke-virtual {v0}, Ljava/util/Calendar;->getTimeZone()Ljava/util/TimeZone;

    move-result-object v0

    const-string v2, "calendar.timeZone"

    invoke-static {v0, v2}, Lkotlin/jvm/internal/Intrinsics;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V

    invoke-direct {v1, v0}, Lcom/demiroren/push/PushSdk$Companion;->getGMTFormat(Ljava/util/TimeZone;)Ljava/lang/String;

    move-result-object v10

    .line 176
    invoke-virtual {v1}, Lcom/demiroren/push/PushSdk$Companion;->getContext()Landroid/content/Context;

    move-result-object v0

    const/4 v2, 0x0

    if-eqz v0, :cond_3a

    invoke-virtual {v0}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;

    move-result-object v0

    goto :goto_3b

    :cond_3a
    move-object v0, v2

    :goto_3b
    const-string v3, "android_id"

    invoke-static {v0, v3}, Landroid/provider/Settings$Secure;->getString(Landroid/content/ContentResolver;Ljava/lang/String;)Ljava/lang/String;

    move-result-object v6

    .line 178
    new-instance v0, Lcom/demiroren/push/model/RegisterRequest;

    .line 182
    invoke-virtual {v1}, Lcom/demiroren/push/PushSdk$Companion;->getToken()Ljava/lang/String;

    move-result-object v7

    const/4 v12, 0x1

    .line 183
    invoke-static {v12}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;

    move-result-object v8

    move-object v3, v0

    move-object v4, p1

    move-object/from16 v5, p3

    move-object/from16 v9, p4

    move-object/from16 v11, p5

    .line 178
    invoke-direct/range {v3 .. v11}, Lcom/demiroren/push/model/RegisterRequest;-><init>(Ljava/util/List;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/Integer;Ljava/lang/Boolean;Ljava/lang/String;Ljava/util/Map;)V

    .line 190
    invoke-virtual {v1}, Lcom/demiroren/push/PushSdk$Companion;->getApiService()Lcom/demiroren/push/ApiService;

    move-result-object v1

    if-eqz v1, :cond_6d

    .line 189
    invoke-static {v1, v2, v0, v12, v2}, Lcom/demiroren/push/ApiService$DefaultImpls;->register$default(Lcom/demiroren/push/ApiService;Ljava/lang/String;Lcom/demiroren/push/model/RegisterRequest;ILjava/lang/Object;)Lretrofit2/Call;

    move-result-object v0

    if-eqz v0, :cond_6d

    .line 190
    new-instance v1, Lcom/demiroren/push/PushSdk$Companion$updateUserData$1;

    invoke-direct {v1}, Lcom/demiroren/push/PushSdk$Companion$updateUserData$1;-><init>()V

    check-cast v1, Lretrofit2/Callback;

    invoke-interface {v0, v1}, Lretrofit2/Call;->enqueue(Lretrofit2/Callback;)V

    :cond_6d
    :goto_6d
    return-void

    .line 162
    :cond_6e
    new-instance v0, Ljava/lang/Exception;

    const-string v1, "Api Service not Created!!"

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

    check-cast v0, Ljava/lang/Throwable;

    throw v0

    .line 159
    :cond_78
    new-instance v0, Ljava/lang/Exception;

    const-string v1, "Retrofit cannot be Null!"

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

    check-cast v0, Ljava/lang/Throwable;

    throw v0
.end method