Last active
December 21, 2020 10:47
-
-
Save lookashc/a5f8baa7c2fa105c66442603ae58c09a to your computer and use it in GitHub Desktop.
medium-feature-toggles-gist1
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
interface Feature<T : Any> { | |
val initialValue: T | |
val name: String | |
fun validate(newValue: T): Boolean = true | |
fun type(): KClass<out T> = initialValue::class | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment