AuditStatus.kt 554 Bytes
Newer Older
1
package org.chronopolis.rest.models.enums
Michael Ritter's avatar
Michael Ritter committed
2

3 4
import com.google.common.collect.ImmutableListMultimap

Michael Ritter's avatar
Michael Ritter committed
5 6 7 8
enum class AuditStatus {
    PRE, AUDITING, SUCCESS, FAIL;

    companion object {
9 10 11 12 13 14 15
        fun statusByGroup(): ImmutableListMultimap<String, AuditStatus> =
                ImmutableListMultimap.Builder<String, AuditStatus>()
                        .put("Pending", PRE)
                        .put("Active", AUDITING)
                        .put("Success", SUCCESS)
                        .put("Failure", FAIL)
                        .build()
Michael Ritter's avatar
Michael Ritter committed
16 17
    }
}