Skip to content

Commit

Permalink
Adding Readme file
Browse files Browse the repository at this point in the history
  • Loading branch information
Shivaprasad Bhat committed Jun 14, 2021
1 parent f47a5d4 commit 3cefe9f
Showing 1 changed file with 34 additions and 0 deletions.
34 changes: 34 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# Android Work Manager - Notify

## About the app

> This application is developed to sending the notification periodically using android's WorkManager. Irrespective of the state (open / closed) the application sends a notification to the user. Every 16th minute, user will get a notification
## Dependencies used in app

- WorkManager
- Timber (for logging)

## Steps to Build the App

- Clone the project from github
- Open the project in Android Studio
- Click the dropdown menu in the toolbar at the top (Open 'Edit Run/Debug configurations' dialog)
- Select "Edit Configurations"
- Click the "+" Button
- Select "Gradle"
- Choose your module as a Gradle project
- In Tasks: enter assemble
- Press Run

Your debug apk will be generated at `<Project Name>/app/build/outputs/apk/debug/`

## Setting Periodic Work Request

```kotlin
val worker = PeriodicWorkRequest.Builder(NotifyWorker::class.java, 15, TimeUnit.MINUTES)
.build()

WorkManager.getInstance(applicationContext).enqueue(worker)
```

0 comments on commit 3cefe9f

Please sign in to comment.