Home > Software design >  What is right place to start a WorkManager in MVVM architecture Android?
What is right place to start a WorkManager in MVVM architecture Android?

Time:06-29

I have a workmanager that every five hours picks up a word from the roomdb and Notification it

I do not know where is the righ place to put the work manager in the MVVM architecture. Should I use in ViewModel or Repository?

CodePudding user response:

I think under datastore package or di package or make one work manager package and finally, work manager class can be used in ApplicationModule under di package,

CodePudding user response:

For the workmanager you only have worker classes, so you need to create a new package names workers or workmanager and place your workers in that package.

  • Related