-
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
8ebbaf4
commit cadac38
Showing
21 changed files
with
330 additions
and
223 deletions.
There are no files selected for viewing
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
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
43 changes: 43 additions & 0 deletions
43
app/src/main/java/com/frogobox/appapi/core/FrogoKoinApplication.kt
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
package com.frogobox.appapi.core | ||
|
||
import com.frogobox.sdk.FrogoApplication | ||
import org.koin.android.ext.koin.androidContext | ||
import org.koin.android.ext.koin.androidLogger | ||
import org.koin.core.KoinApplication | ||
import org.koin.core.context.startKoin | ||
import org.koin.core.logger.Level | ||
|
||
|
||
/** | ||
* Created by faisalamir on 26/07/21 | ||
* FrogoSDK | ||
* ----------------------------------------- | ||
* Name : Muhammad Faisal Amir | ||
* E-mail : faisalamircs@gmail.com | ||
* Github : github.com/amirisback | ||
* ----------------------------------------- | ||
* Copyright (C) 2021 FrogoBox Inc. | ||
* All rights reserved | ||
* | ||
*/ | ||
|
||
abstract class FrogoKoinApplication : FrogoApplication() { | ||
|
||
open fun setupKoinModule(koinApplication: KoinApplication) {} | ||
|
||
override fun onCreateExt() { | ||
super.onCreateExt() | ||
startKoin { | ||
androidContext(this@FrogoKoinApplication) | ||
androidLogger( | ||
if (isDebugMode()) { | ||
Level.DEBUG | ||
} else { | ||
Level.ERROR | ||
} | ||
) | ||
setupKoinModule(this) | ||
} | ||
} | ||
|
||
} |
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
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
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
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
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
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
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
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
Oops, something went wrong.