common-codes

Installation
SKILL.md

Common codes & enums

Overview

This document defines rules for categorized domain codes as enums. All domain enums that represent classifiable codes must implement the CommonCode interface from the common module.

Key Principle: All categorized domain codes must implement CommonCode. Always persist enums as STRING in JPA entities — never use ORDINAL.

CommonCode interface

CommonCode in io.glory.common.codes defines the contract for all domain code enums.

interface CommonCode {
    val code: String        // Machine-readable code value
    val description: String // Human-readable description
    val name: String        // Enum constant name (provided by Kotlin enum)
}
Installs
1
First Seen
Apr 10, 2026