/*
 * The contents of this file are subject to the Mozilla Public License
 * Version 1.1 (the "License");  you may not use this file except in 
 * compliance with the License.  You may obtain a copy of the License at
 * http://www.mozilla.org/MPL/
 *
 * Software distributed under the License is distributed on an "AS IS" basis,
 * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for
 * the specific language governing rights and limitations under the License.
 *
 * The Original Code is Protege-2000.
 *
 * The Initial Developer of the Original Code is Stanford University. Portions
 * created by Stanford University are Copyright (C) 2007.  All Rights Reserved.
 *
 * Protege was developed by Stanford Medical Informatics
 * (http://www.smi.stanford.edu) at the Stanford University School of Medicine
 * with support from the National Library of Medicine, the National Science
 * Foundation, and the Defense Advanced Research Projects Agency.  Current
 * information about Protege can be obtained at http://protege.stanford.edu.
 *
 */

package edu.stanford.smi.protege.storage.database;

public enum KnownDatabase {
    MYSQL(true, "mysql", 
          "VARBINARY(500)", 
          "VARCHAR(500) COLLATE utf8_general_ci", 500,
          "MEDIUMTEXT",
          "BIT", "SMALLINT", "INT"),
    POSTGRESQL(true, "postgresql",
               "VARCHAR(500)", 
               "VARCHAR(500)", 500,
               "TEXT",
               "BOOL", "INT2", "INT4"),
    SQLSERVER(true, "MsSqlServer",
              "VARCHAR(255) COLLATE SQL_Latin1_General_CP1_CS_AS",
              "VARCHAR(255) COLLATE SQL_Latin1_General_CP1_CS_AS", 255,
              "NTEXT",
              "BIT", "SMALLINT", "INT"),
    ORACLE(true, "oracle",
           "VARCHAR2(1900)", 
           "VARCHAR2(1900)", 1900,
           "LONG",
           "SMALLINT", "SMALLINT", "INTEGER"),
    DERBY(false, "derby",
          "VARCHAR(500)",
          "VARCHAR(500)", 500,
          "LONG VARCHAR",
          "SMALLINT","SMALLINT","INTEGER")
    ;

    private boolean supported;
    private String  shortName;
    private String  frameNameType;
    private String  shortValueType;
    private int     maxShortValueSize;
    private String  longStringType;
    private String  bitType;
    private String  smallIntType;
    private String  intType;

    private KnownDatabase(boolean supported,
                          String shortName, 
                          String frameNameType, 
                          String shortValueType,
                          int maxShortValueSize,
                          String longStringType, 
                          String bitType,
                          String smallIntType, 
                          String intType) {
        this.supported = supported;
        this.shortName = shortName;
        this.frameNameType = frameNameType;
        this.shortValueType = shortValueType;
        this.maxShortValueSize = maxShortValueSize;
        this.longStringType = longStringType;
        this.bitType = bitType;
        this.smallIntType = smallIntType;
        this.intType = intType;
    }
    
    public boolean getSupported() {
        return supported;
    }

    public String getShortName() {
        return shortName;
    }

    public String getFrameNameType() {
        return frameNameType;
    }

    public String getShortValueType() {
        return shortValueType;
    }

    public int getMaxShortValueSize() {
        return maxShortValueSize;
    }

    public String getLongStringType() {
        return longStringType;
    }

    public String getBitType() {
        return bitType;
    }

    public String getSmallIntType() {
        return smallIntType;
    }

    public String getIntType() {
        return intType;
    }


    public static void main(String [] args) {
        
    }
}
