public static DirType fromValue(String v) {
        for (DirType c: DirType.values()) {
            if (c.value.equals(v)) {
                return c;
            }
        }
        throw new IllegalArgumentException(v);
    }