Created
September 15, 2021 09:52
-
-
Save Priyansh-Kedia/e60993a77759282038bf946021d33c66 to your computer and use it in GitHub Desktop.
Companion object in UploadService
This file contains 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
companion object { | |
/** | |
* Unique job ID for this service. | |
*/ | |
const val JOB_ID = 1000 | |
const val IMAGE_URI = "image_uri" | |
const val IMAGE_URL = "image_url" | |
const val DOCUMENT_URI = "document_uri" | |
const val DOCUMENT_URL = "document_url" | |
/** | |
* Convenience method for enqueuing work in to this service. | |
*/ | |
fun enqueueWork(context: Context, work: Intent?) { | |
enqueueWork(context, | |
UploadService::class.java, JOB_ID, | |
work!!) | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment