provideAppDatabase

@Provides
@Singleton
fun provideAppDatabase(context: Context): AppDatabase

Provide an instance of AppDatabase. This method is annotated with @Provides to indicate that it should be used to create instances of AppDatabase.

Return

an instance of AppDatabase.

Parameters

context

the application context to use to create the database.