incendium / enum-utils

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Kotlin - Enum Utils

Maven Central Sonatype Nexus (Snapshots) GitHub

This project is a simple utility library that helps in constructing lookup tables for enums and creating sealed class hierarchies that function similar to enums. The latter can be useful if for maintaining type safety in the event that an unknown value is received, but preserving the value is desirable over converting it to an standardized "UNKNOWN" value.

Installation

Add the following to your gradle.build or gradle.build.kts file:

// build.gradle.kts
dependencies {
    implementation("com.iamincendium.common:enum-utils:0.1.0")
}

Refer to the KDocs for more information on usage.

About

License:ISC License


Languages

Language:Kotlin 100.0%