Skip to content

Instantly share code, notes, and snippets.

🎯
Focusing

Tomasz tmaxxdd

🎯
Focusing
Block or report user

Report or block tmaxxdd

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@tmaxxdd
tmaxxdd / kotlin_kapt
Created Aug 1, 2019
Unresolved reference Dagger
View kotlin_kapt
apply plugin: 'kotlin-kapt'
View rxjava_dispose.java
@Override
protected void onPause() {
super.onPause();
textWatcher.dispose(); // Konczy emisje i zamyka watek
}
View pass_regex.java
private boolean isPasswordValid(CharSequence pass) {
/*
^ # start-of-string
(?=.*[0-9]) # a digit must occur at least once
(?=.*[a-z]) # a lower case letter must occur at least once
(?=.*[A-Z]) # an upper case letter must occur at least once
(?=.*[@#$%^&+=]) # a special character must occur at least once
.{8,} # anything, at least eight places though
$ # end-of-string
*/
View input_validator.java
...
private Disposable textWatcher;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
AppCompatEditText input = findViewById(R.id.password);
View java_8_config
android {
...
compileOptions {
sourceCompatibility = '1.8'
targetCompatibility = '1.8'
}
}
View rxbinding_import
implementation 'com.jakewharton.rxbinding2:rxbinding:2.1.1'
View rxjava_import
implementation 'io.reactivex.rxjava2:rxjava:2.2.10'
View activity_main.xml
<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".MainActivity">
<androidx.appcompat.widget.AppCompatEditText
android:layout_width="match_parent"
View topics_fragment.kt
private lateinit var presenter: TopicsPresenter
...
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
presenter = TopicsPresenter(dataRepository)
}
...
override fun onResume() {
You can’t perform that action at this time.