Skip to content

Instantly share code, notes, and snippets.

View einarvalgeirsson's full-sized avatar

Einar Valgeirsson einarvalgeirsson

  • Jayway
  • Malmö, Sweden
View GitHub Profile
@einarvalgeirsson
einarvalgeirsson / AnyExtension.kt
Created November 13, 2017 20:33
Avoid having to declare TAG in all your class files
val Any.TAG: String
get() {
val klass = this.javaClass
return if(klass.isAnonymousClass) {
klass.enclosingClass.simpleName
} else {
klass.simpleName
}
}

Keybase proof

I hereby claim:

  • I am einarvalgeirsson on github.
  • I am einarv (https://keybase.io/einarv) on keybase.
  • I have a public key whose fingerprint is 05B0 6BEC 14E9 2B41 F586 C424 DE44 61D1 3089 C60B

To claim this, I am signing this object:

@einarvalgeirsson
einarvalgeirsson / KotlinPresentation.kt
Created September 1, 2017 09:13
Big Kotlin file used for "Introduction to Kotlin" presentation at Jayway Kday 1 Sept '17
package org.jetbrains.kotlinworkshop.introduction.Einar