package org.mousephenotype.cda.enumerations;

public enum LifeStage {
    E9_5("E9.5"),
    E12_5("E12.5"),
    E15_5("E15.5"),
    E18_5("E18.5"),
    EARLY_ADULT("Early adult"),
    MIDDLE_AGED_ADULT("Middle aged adult"),
    LATE_ADULT("Late adult");

    private final String name;

    LifeStage(String name) {
        this.name = name;
    }

    public String getName() {
        return this.toString();
    }
}
@@ -410,9 +410,932 @@
 ;%0A    %7D%0A
+%0A    public static LifeStage getByDisplayName(String displayName) %7B%0A        switch (displayName.toLowerCase()) %7B%0A            case %22e9.5%22:%0A            case %22embryonic day 9.5%22:%0A                return LifeStage.E9_5;%0A            case %22e12.5%22:%0A            case %22embryonic day 12.5%22:%0A                return LifeStage.E12_5;%0A            case %22e15.5%22:%0A            case %22embryonic day 15.5%22:%0A                return LifeStage.E15_5;%0A            case %22e18.5%22:%0A            case %22embryonic day 18.5%22:%0A                return LifeStage.E18_5;%0A            case %22early adult%22:%0A                return LifeStage.EARLY_ADULT;%0A            case %22middle aged adult%22:%0A                return LifeStage.MIDDLE_AGED_ADULT;%0A            case %22late adult%22:%0A                return LifeStage.LATE_ADULT;%0A            default:%0A                throw new IllegalArgumentException(%22No enum constant %22 + LifeStage.class + %22.%22 + displayName);%0A        %7D%0A    %7D%0A%0A
 %7D

Add get LifeStage from string method to enum