00001 using System; 00002 using System.Data; 00003 00004 using SQLiteCSLib.Inner; 00005 00006 namespace SQLiteCSLib 00007 { 00011 public class SQLiteException : DataException 00012 { 00016 protected ResultEnum m_errcode = ResultEnum.ERROR; 00017 00022 public SQLiteException( SQLiteConnection connect ) : base( (connect != null ) ? connect.OSQLiteDB.getLastErrMsg():"Fail!!" ) 00023 { 00024 if( connect != null ) 00025 { 00026 m_errcode = (ResultEnum)connect.OSQLiteDB.getLastErr(); 00027 } 00028 } 00029 00034 public SQLiteException( OSQLiteStmtWrap stmt ) : base( (stmt != null ) ? stmt.DbWrap().getLastErrMsg():"Fail!!" ) 00035 { 00036 if( stmt != null ) 00037 { 00038 m_errcode = (ResultEnum)stmt.DbWrap().getLastErr(); 00039 } 00040 } 00041 } 00042 }