// Path: acpg-lib/src/main/java/org/jraf/acpg/lib/GeneratorException.java
// public class GeneratorException extends Exception {
//     public GeneratorException(String message) {
//         super(message);
//     }
// 
//     public GeneratorException(String message, Throwable cause) {
//         super(message, cause);
//     }
// }


import org.apache.commons.lang.WordUtils;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.jraf.acpg.lib.GeneratorException;
import java.util.ArrayList;
import java.util.Date;
import java.util.HashMap;
import java.util.List;
import java.util.Locale;
    private static final String ON_DELETE_ACTION_SET_DEFAULT = "SET DEFAULT";
    private static final String ON_DELETE_ACTION_CASCADE = "CASCADE";

    public enum Type {
        // @formatter:off
        STRING(TYPE_STRING, "TEXT", String.class, String.class),
        INTEGER(TYPE_INTEGER, "INTEGER", Integer.class, int.class),
        LONG(TYPE_LONG, "INTEGER", Long.class, long.class),
        FLOAT(TYPE_FLOAT, "REAL", Float.class, float.class),
        DOUBLE(TYPE_DOUBLE, "REAL", Double.class, double.class),
        BOOLEAN(TYPE_BOOLEAN, "INTEGER", Boolean.class, boolean.class),
        DATE(TYPE_DATE, "INTEGER", Date.class, Date.class),
        BYTE_ARRAY(TYPE_BYTE_ARRAY, "BLOB", byte[].class, byte[].class),
        ENUM(TYPE_ENUM, "INTEGER", null, null),
        // @formatter:on
        ;

        private String mJsonName;
        private String mSqlType;
        private Class<?> mNullableJavaType;
        private Class<?> mNotNullableJavaType;

        private Type(String jsonName, String sqlType, Class<?> nullableJavaType, Class<?> notNullableJavaType) {
            mJsonName = jsonName;
            mSqlType = sqlType;
            mNullableJavaType = nullableJavaType;
            mNotNullableJavaType = notNullableJavaType;
            sTypeJsonNames.put(jsonName, this);
        }

// Path: acpg-lib/src/main/java/org/jraf/acpg/lib/GeneratorException.java
// public class GeneratorException extends Exception {
//     public GeneratorException(String message) {
//         super(message);
//     }
// 
//     public GeneratorException(String message, Throwable cause) {
//         super(message, cause);
//     }
// }


// Path: acpg-lib/src/main/java/org/jraf/acpg/lib/model/Field.java
import org.apache.commons.lang.WordUtils;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.jraf.acpg.lib.GeneratorException;
import java.util.ArrayList;
import java.util.Date;
import java.util.HashMap;
import java.util.List;
import java.util.Locale;

    private static final String ON_DELETE_ACTION_SET_DEFAULT = "SET DEFAULT";
    private static final String ON_DELETE_ACTION_CASCADE = "CASCADE";

    public enum Type {
        // @formatter:off
        STRING(TYPE_STRING, "TEXT", String.class, String.class),
        INTEGER(TYPE_INTEGER, "INTEGER", Integer.class, int.class),
        LONG(TYPE_LONG, "INTEGER", Long.class, long.class),
        FLOAT(TYPE_FLOAT, "REAL", Float.class, float.class),
        DOUBLE(TYPE_DOUBLE, "REAL", Double.class, double.class),
        BOOLEAN(TYPE_BOOLEAN, "INTEGER", Boolean.class, boolean.class),
        DATE(TYPE_DATE, "INTEGER", Date.class, Date.class),
        BYTE_ARRAY(TYPE_BYTE_ARRAY, "BLOB", byte[].class, byte[].class),
        ENUM(TYPE_ENUM, "INTEGER", null, null),
        // @formatter:on
        ;

        private String mJsonName;
        private String mSqlType;
        private Class<?> mNullableJavaType;
        private Class<?> mNotNullableJavaType;

        private Type(String jsonName, String sqlType, Class<?> nullableJavaType, Class<?> notNullableJavaType) {
            mJsonName = jsonName;
            mSqlType = sqlType;
            mNullableJavaType = nullableJavaType;
            mNotNullableJavaType = notNullableJavaType;
            sTypeJsonNames.put(jsonName, this);
        }

        public static Type fromJsonName(String jsonName) throws GeneratorException {