SqlDbTypeToValueType() static private méthode

static private SqlDbTypeToValueType ( SqlDbType sqlDbType ) : Type
sqlDbType SqlDbType
Résultat System.Type
        protected internal sealed override object ConvertValue(object value)
        {
            // can not convert null or DbNull to other types
            if (value == null || value == DBNull.Value)
            {
                return(value);
            }
            // .NET throws an exception to the user.
            object convertedValue = value is IConvertible?Convert.ChangeType(value, SqlConvert.SqlDbTypeToValueType(SqlDbType)) : value;

            return(convertedValue);
        }