Enum SqlType

    • Enum Constant Detail

      • VARCHAR

        public static final SqlType VARCHAR
        String.
      • DATE

        public static final SqlType DATE
        Date.
      • TIME

        public static final SqlType TIME
        Time.
      • TIMESTAMP

        public static final SqlType TIMESTAMP
        Timestamp.
      • BLOB

        public static final SqlType BLOB
        Arbitrary data usually stored as BLOB.
      • CLOB

        public static final SqlType CLOB
        Large Strings usually stored as CLOB.
      • DECIMAL

        public static final SqlType DECIMAL
        BigDecimal and DMoney.
      • CHAR

        public static final SqlType CHAR
        Character and char.
      • BIT

        public static final SqlType BIT
        Boolean and boolean.
      • TINYINT

        public static final SqlType TINYINT
        Byte and byte.
      • SMALLINT

        public static final SqlType SMALLINT
        Short and short.
      • INTEGER

        public static final SqlType INTEGER
        Integer and int.
      • BIGINT

        public static final SqlType BIGINT
        Long and long.
      • FLOAT

        public static final SqlType FLOAT
        Float and float.
      • DOUBLE

        public static final SqlType DOUBLE
        Double and double.
      • JAVA_OBJECT

        public static final SqlType JAVA_OBJECT
        Application specific.
    • Method Detail

      • values

        public static SqlType[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (SqlType c : SqlType.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static SqlType valueOf​(String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        name - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        IllegalArgumentException - if this enum type has no constant with the specified name
        NullPointerException - if the argument is null
      • getClazz

        public Class<?> getClazz()
        Gets the corresponding class.
        Returns:
        the class
      • getDefaultValue

        public Object getDefaultValue()
        Gets the default value.
        Returns:
        the default, null if no default
      • parse

        public Object parse​(String str)
        Parses the string and converts to a java-value.
        Parameters:
        str - the string usually returned from JDBC metadata
        Returns:
        the java value