apkfuckery/com.discord/smali/androidx/work/Configuration$Builder.smali

179 lines
4.6 KiB
Smali
Raw Normal View History

2019-07-24 11:27:29 +00:00
.class public final Landroidx/work/Configuration$Builder;
.super Ljava/lang/Object;
.source "Configuration.java"
# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
value = Landroidx/work/Configuration;
.end annotation
.annotation system Ldalvik/annotation/InnerClass;
accessFlags = 0x19
name = "Builder"
.end annotation
# instance fields
2019-12-06 03:29:40 +00:00
.field public mExecutor:Ljava/util/concurrent/Executor;
2019-07-24 11:27:29 +00:00
2019-12-06 03:29:40 +00:00
.field public mLoggingLevel:I
2019-07-24 11:27:29 +00:00
2019-12-06 03:29:40 +00:00
.field public mMaxJobSchedulerId:I
2019-07-24 11:27:29 +00:00
2019-12-06 03:29:40 +00:00
.field public mMaxSchedulerLimit:I
2019-07-24 11:27:29 +00:00
2019-12-06 03:29:40 +00:00
.field public mMinJobSchedulerId:I
2019-07-24 11:27:29 +00:00
2019-12-06 03:29:40 +00:00
.field public mTaskExecutor:Ljava/util/concurrent/Executor;
2019-10-07 23:23:22 +00:00
2019-12-06 03:29:40 +00:00
.field public mWorkerFactory:Landroidx/work/WorkerFactory;
2019-07-24 11:27:29 +00:00
# direct methods
.method public constructor <init>()V
.locals 1
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
const/4 v0, 0x4
iput v0, p0, Landroidx/work/Configuration$Builder;->mLoggingLevel:I
const/4 v0, 0x0
iput v0, p0, Landroidx/work/Configuration$Builder;->mMinJobSchedulerId:I
const v0, 0x7fffffff
iput v0, p0, Landroidx/work/Configuration$Builder;->mMaxJobSchedulerId:I
const/16 v0, 0x14
iput v0, p0, Landroidx/work/Configuration$Builder;->mMaxSchedulerLimit:I
return-void
.end method
# virtual methods
2019-12-06 03:29:40 +00:00
.method public build()Landroidx/work/Configuration;
2019-07-24 11:27:29 +00:00
.locals 1
2019-12-06 03:29:40 +00:00
.annotation build Landroidx/annotation/NonNull;
.end annotation
2019-07-24 11:27:29 +00:00
new-instance v0, Landroidx/work/Configuration;
invoke-direct {v0, p0}, Landroidx/work/Configuration;-><init>(Landroidx/work/Configuration$Builder;)V
return-object v0
.end method
2019-12-06 03:29:40 +00:00
.method public setExecutor(Ljava/util/concurrent/Executor;)Landroidx/work/Configuration$Builder;
2019-07-24 11:27:29 +00:00
.locals 0
2019-12-06 03:29:40 +00:00
.param p1 # Ljava/util/concurrent/Executor;
.annotation build Landroidx/annotation/NonNull;
.end annotation
.end param
.annotation build Landroidx/annotation/NonNull;
.end annotation
2019-07-24 11:27:29 +00:00
iput-object p1, p0, Landroidx/work/Configuration$Builder;->mExecutor:Ljava/util/concurrent/Executor;
return-object p0
.end method
2019-12-06 03:29:40 +00:00
.method public setJobSchedulerJobIdRange(II)Landroidx/work/Configuration$Builder;
2019-07-24 11:27:29 +00:00
.locals 2
2019-12-06 03:29:40 +00:00
.annotation build Landroidx/annotation/NonNull;
.end annotation
2019-07-24 11:27:29 +00:00
sub-int v0, p2, p1
const/16 v1, 0x3e8
if-lt v0, v1, :cond_0
iput p1, p0, Landroidx/work/Configuration$Builder;->mMinJobSchedulerId:I
iput p2, p0, Landroidx/work/Configuration$Builder;->mMaxJobSchedulerId:I
return-object p0
:cond_0
new-instance p1, Ljava/lang/IllegalArgumentException;
const-string p2, "WorkManager needs a range of at least 1000 job ids."
invoke-direct {p1, p2}, Ljava/lang/IllegalArgumentException;-><init>(Ljava/lang/String;)V
throw p1
.end method
2019-12-06 03:29:40 +00:00
.method public setMaxSchedulerLimit(I)Landroidx/work/Configuration$Builder;
2019-07-24 11:27:29 +00:00
.locals 1
2019-12-06 03:29:40 +00:00
.annotation build Landroidx/annotation/NonNull;
.end annotation
2019-07-24 11:27:29 +00:00
const/16 v0, 0x14
if-lt p1, v0, :cond_0
const/16 v0, 0x32
invoke-static {p1, v0}, Ljava/lang/Math;->min(II)I
move-result p1
iput p1, p0, Landroidx/work/Configuration$Builder;->mMaxSchedulerLimit:I
return-object p0
:cond_0
new-instance p1, Ljava/lang/IllegalArgumentException;
const-string v0, "WorkManager needs to be able to schedule at least 20 jobs in JobScheduler."
invoke-direct {p1, v0}, Ljava/lang/IllegalArgumentException;-><init>(Ljava/lang/String;)V
throw p1
.end method
2019-12-06 03:29:40 +00:00
.method public setMinimumLoggingLevel(I)Landroidx/work/Configuration$Builder;
2019-07-24 11:27:29 +00:00
.locals 0
2019-12-06 03:29:40 +00:00
.annotation build Landroidx/annotation/NonNull;
.end annotation
2019-07-24 11:27:29 +00:00
iput p1, p0, Landroidx/work/Configuration$Builder;->mLoggingLevel:I
return-object p0
.end method
2019-12-06 03:29:40 +00:00
.method public setTaskExecutor(Ljava/util/concurrent/Executor;)Landroidx/work/Configuration$Builder;
2019-10-07 23:23:22 +00:00
.locals 0
2019-12-06 03:29:40 +00:00
.param p1 # Ljava/util/concurrent/Executor;
.annotation build Landroidx/annotation/NonNull;
.end annotation
.end param
.annotation build Landroidx/annotation/NonNull;
.end annotation
2019-10-07 23:23:22 +00:00
iput-object p1, p0, Landroidx/work/Configuration$Builder;->mTaskExecutor:Ljava/util/concurrent/Executor;
return-object p0
.end method
2019-12-06 03:29:40 +00:00
.method public setWorkerFactory(Landroidx/work/WorkerFactory;)Landroidx/work/Configuration$Builder;
2019-07-24 11:27:29 +00:00
.locals 0
2019-12-06 03:29:40 +00:00
.param p1 # Landroidx/work/WorkerFactory;
.annotation build Landroidx/annotation/NonNull;
.end annotation
.end param
.annotation build Landroidx/annotation/NonNull;
.end annotation
2019-07-24 11:27:29 +00:00
iput-object p1, p0, Landroidx/work/Configuration$Builder;->mWorkerFactory:Landroidx/work/WorkerFactory;
return-object p0
.end method