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
package com.westwingnow.android.utils | |
import android.os.SystemClock | |
import android.view.View | |
import java.util.* | |
/** | |
* A Throttled OnClickListener | |
* Rejects clicks that are too close together in time. | |
* This class is safe to use as an OnClickListener for multiple views, and will throttle each one separately. |
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
var edit: EditText = findViewById(R.id.editField) as EditText | |
println(exit.text) |
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
val actionBar = supportActionBar | |
actionBar!!.title = "New Title" | |
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
package main | |
import com.github.kittinunf.fuel.httpGet | |
import com.github.kittinunf.result.Result | |
import com.squareup.moshi.JsonAdapter | |
import com.squareup.moshi.Moshi | |
import com.squareup.moshi.Types | |
import com.squareup.moshi.kotlin.reflect.KotlinJsonAdapterFactory | |
import java.lang.reflect.Type |
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
package main | |
import com.squareup.moshi.JsonAdapter | |
import com.squareup.moshi.JsonReader | |
import com.squareup.moshi.Moshi | |
import com.squareup.moshi.kotlin.reflect.KotlinJsonAdapterFactory | |
class Person(val id: Int, val name: String) | |
fun main() { |