This file contains hidden or 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
| android { | |
| compileOptions { | |
| sourceCompatibility JavaVersion.VERSION_1_8 | |
| targetCompatibility JavaVersion.VERSION_1_8 | |
| } | |
| } |
This file contains hidden or 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
| plugins { | |
| id "org.jetbrains.kotlin.kapt" | |
| id "dagger.hilt.android.plugin" | |
| } | |
| dependencies { | |
| implementation "com.google.dagger:hilt-android:$hilt_version" | |
| kapt "com.google.dagger:hilt-android-compiler:$hilt_version" | |
| } |
This file contains hidden or 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
| buildscript { | |
| ext.hilt_version = "2.35" | |
| dependencies { | |
| classpath "com.google.dagger:hilt-android-gradle-plugin:$hilt_version" | |
| } | |
| } |
This file contains hidden or 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
| public abstract class Hilt_HiltSampleApp extends Application implements GeneratedComponentManagerHolder { | |
| private final ApplicationComponentManager componentManager = new ApplicationComponentManager(new ComponentSupplier() { | |
| @Override | |
| public Object get() { | |
| return DaggerHiltSampleApp_HiltComponents_SingletonC.builder() | |
| .applicationContextModule(new ApplicationContextModule(Hilt_HiltSampleApp.this)) | |
| .build(); | |
| } | |
| }); |
This file contains hidden or 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
| public final class DaggerHiltSampleApp_HiltComponents_SingletonC extends HiltSampleApp_HiltComponents.SingletonC { | |
| private final ApplicationContextModule applicationContextModule; | |
| private DaggerHiltSampleApp_HiltComponents_SingletonC( | |
| ApplicationContextModule applicationContextModuleParam) { | |
| this.applicationContextModule = applicationContextModuleParam; | |
| } | |
| ...... | |
| } |
This file contains hidden or 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
| class CalculatorPresenter : Contract.Presenter { | |
| private lateinit var view: Contract.View | |
| private val data: Stack<String> = Stack() | |
| override fun recordInput(value: String, currentResult: String) { | |
| if (value.isOperator()) { | |
| data.push(currentResult) |
This file contains hidden or 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
| final int version = android.os.Build.VERSION.SDK_INT; | |
| if(version < android.os.Build.VERSION_CODES.JELLY_BEAN) { | |
| layout.setBackgroundDrawable( getDrawable(context, R.drawable.ready) ); | |
| } else { | |
| layout.setBackground( getDrawable(context, R.drawable.ready)); | |
| } |