Created
September 19, 2019 15:07
-
-
Save neonankiti/47dead3d84d2db5fd1c179018eb22268 to your computer and use it in GitHub Desktop.
Worker settings for WorkManager sample
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class Repository @Inject constructor() | |
| class BisonWorker @AssistedInject constructor( | |
| @Assisted private val appContext: Context, | |
| @Assisted private val params: WorkerParameters, | |
| private val repository: Repository | |
| ) : Worker(appContext, params) { | |
| override fun doWork(): Result { | |
| return Result.success() | |
| } | |
| @AssistedInject.Factory | |
| interface Factory : ChildWorkerFactory | |
| companion object { | |
| private const val TAG = "BisonWorker" | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment