RongJobIntentService$JobServiceEngineImpl.smali
.class final Lio/rong/imlib/RongJobIntentService$JobServiceEngineImpl;
.super Landroid/app/job/JobServiceEngine;
.source "RongJobIntentService.java"
# interfaces
.implements Lio/rong/imlib/RongJobIntentService$CompatJobEngine;
# annotations
.annotation build Landroid/annotation/SuppressLint;
value = {
"NewApi"
}
.end annotation
.annotation system Ldalvik/annotation/EnclosingClass;
value = Lio/rong/imlib/RongJobIntentService;
.end annotation
.annotation system Ldalvik/annotation/InnerClass;
accessFlags = 0x18
name = "JobServiceEngineImpl"
.end annotation
.annotation system Ldalvik/annotation/MemberClasses;
value = {
Lio/rong/imlib/RongJobIntentService$JobServiceEngineImpl$WrapperWorkItem;
}
.end annotation
# static fields
.field static final DEBUG:Z = false
.field static final TAG:Ljava/lang/String; = "JobServiceEngineImpl"
# instance fields
.field final mLock:Ljava/lang/Object;
.field mParams:Landroid/app/job/JobParameters;
.field final mService:Lio/rong/imlib/RongJobIntentService;
# direct methods
.method constructor <init>(Lio/rong/imlib/RongJobIntentService;)V
.registers 3
.line 1
invoke-direct {p0, p1}, Landroid/app/job/JobServiceEngine;-><init>(Landroid/app/Service;)V
.line 2
new-instance v0, Ljava/lang/Object;
invoke-direct {v0}, Ljava/lang/Object;-><init>()V
iput-object v0, p0, Lio/rong/imlib/RongJobIntentService$JobServiceEngineImpl;->mLock:Ljava/lang/Object;
.line 3
iput-object p1, p0, Lio/rong/imlib/RongJobIntentService$JobServiceEngineImpl;->mService:Lio/rong/imlib/RongJobIntentService;
return-void
.end method
# virtual methods
.method public compatGetBinder()Landroid/os/IBinder;
.registers 2
.line 1
invoke-virtual {p0}, Landroid/app/job/JobServiceEngine;->getBinder()Landroid/os/IBinder;
move-result-object v0
return-object v0
.end method
.method public dequeueWork()Lio/rong/imlib/RongJobIntentService$GenericWorkItem;
.registers 5
.line 1
iget-object v0, p0, Lio/rong/imlib/RongJobIntentService$JobServiceEngineImpl;->mLock:Ljava/lang/Object;
monitor-enter v0
.line 2
:try_start_3
iget-object v1, p0, Lio/rong/imlib/RongJobIntentService$JobServiceEngineImpl;->mParams:Landroid/app/job/JobParameters;
const/4 v2, 0x0
if-nez v1, :cond_a
.line 3
monitor-exit v0
:try_end_9
.catchall {:try_start_3 .. :try_end_9} :catchall_30
return-object v2
.line 4
:cond_a
:try_start_a
iget-object v1, p0, Lio/rong/imlib/RongJobIntentService$JobServiceEngineImpl;->mParams:Landroid/app/job/JobParameters;
invoke-virtual {v1}, Landroid/app/job/JobParameters;->dequeueWork()Landroid/app/job/JobWorkItem;
move-result-object v1
:try_end_10
.catch Ljava/lang/Exception; {:try_start_a .. :try_end_10} :catch_11
.catchall {:try_start_a .. :try_end_10} :catchall_30
goto :goto_19
:catch_11
:try_start_11
const-string v1, "JobServiceEngineImpl"
const-string v3, "Catch exception when dequeue work."
.line 5
invoke-static {v1, v3}, Lio/rong/common/rlog/RLog;->w(Ljava/lang/String;Ljava/lang/String;)I
move-object v1, v2
.line 6
:goto_19
monitor-exit v0
:try_end_1a
.catchall {:try_start_11 .. :try_end_1a} :catchall_30
if-eqz v1, :cond_2f
.line 7
invoke-virtual {v1}, Landroid/app/job/JobWorkItem;->getIntent()Landroid/content/Intent;
move-result-object v0
iget-object v2, p0, Lio/rong/imlib/RongJobIntentService$JobServiceEngineImpl;->mService:Lio/rong/imlib/RongJobIntentService;
invoke-virtual {v2}, Landroid/app/Service;->getClassLoader()Ljava/lang/ClassLoader;
move-result-object v2
invoke-virtual {v0, v2}, Landroid/content/Intent;->setExtrasClassLoader(Ljava/lang/ClassLoader;)V
.line 8
new-instance v0, Lio/rong/imlib/RongJobIntentService$JobServiceEngineImpl$WrapperWorkItem;
invoke-direct {v0, p0, v1}, Lio/rong/imlib/RongJobIntentService$JobServiceEngineImpl$WrapperWorkItem;-><init>(Lio/rong/imlib/RongJobIntentService$JobServiceEngineImpl;Landroid/app/job/JobWorkItem;)V
return-object v0
:cond_2f
return-object v2
:catchall_30
move-exception v1
.line 9
:try_start_31
monitor-exit v0
:try_end_32
.catchall {:try_start_31 .. :try_end_32} :catchall_30
throw v1
.end method
.method public onStartJob(Landroid/app/job/JobParameters;)Z
.registers 3
.line 1
iput-object p1, p0, Lio/rong/imlib/RongJobIntentService$JobServiceEngineImpl;->mParams:Landroid/app/job/JobParameters;
.line 2
iget-object p1, p0, Lio/rong/imlib/RongJobIntentService$JobServiceEngineImpl;->mService:Lio/rong/imlib/RongJobIntentService;
const/4 v0, 0x0
invoke-virtual {p1, v0}, Lio/rong/imlib/RongJobIntentService;->ensureProcessorRunningLocked(Z)V
const/4 p1, 0x1
return p1
.end method
.method public onStopJob(Landroid/app/job/JobParameters;)Z
.registers 4
.line 1
iget-object p1, p0, Lio/rong/imlib/RongJobIntentService$JobServiceEngineImpl;->mService:Lio/rong/imlib/RongJobIntentService;
invoke-virtual {p1}, Lio/rong/imlib/RongJobIntentService;->doStopCurrentWork()Z
move-result p1
.line 2
iget-object v0, p0, Lio/rong/imlib/RongJobIntentService$JobServiceEngineImpl;->mLock:Ljava/lang/Object;
monitor-enter v0
const/4 v1, 0x0
.line 3
:try_start_a
iput-object v1, p0, Lio/rong/imlib/RongJobIntentService$JobServiceEngineImpl;->mParams:Landroid/app/job/JobParameters;
.line 4
monitor-exit v0
return p1
:catchall_e
move-exception p1
monitor-exit v0
:try_end_10
.catchall {:try_start_a .. :try_end_10} :catchall_e
throw p1
.end method