//--------------------------------------------------------------------------
 // used to export to xml
 public static void FillDataSet(DataSet ds)
 {
     DaoUtils.FillDataSet(kSQLSelectAll, kTableRelation, ds);
     DaoUtils.FillDataSet(kSQLSelectAllRelationsWords,
                          kTableRelationsWords,
                          ds);
 }
 //--------------------------------------------------------------------------
 // used to export to xml
 public static void FillDataSet(DataSet ds)
 {
     DaoUtils.FillDataSet("SELECT * FROM " + kTablePhrase,
                          kTablePhrase,
                          ds);
     DaoUtils.FillDataSet("SELECT * FROM " + kTablePhrasesWords,
                          kTablePhrasesWords,
                          ds);
 }
Beispiel #3
0
        //--------------------------------------------------------------------------
        private static Document MapDocument(MySqlDataReader reader)
        {
            Document document = new Document()
            {
                Id             = reader.GetInt32(kFieldId),
                GutenbergId    = reader.GetString(kFieldGutenbergId),
                Title          = reader.GetString(kFieldTitle),
                Author         = reader.GetString(kFieldAuthor),
                LocalFile      = new FileInfo(reader.GetString(kFieldLocalFilename)),
                ReleaseDate    = DaoUtils.SafeGetDateTime(reader, kFieldReleaseDate),
                TableLoadState = (Document.LoadState)reader.GetInt32(kFieldLoadState)
            };

            return(document);
        }
 //--------------------------------------------------------------------------
 public static void CreateTable()
 {
     DaoUtils.ExecuteNonQuery(kSQLCreateTableGroup);
     DaoUtils.ExecuteNonQuery(kSQLCreateTableGroupsWords);
 }
 //--------------------------------------------------------------------------
 public static void DropTable()
 {
     DaoUtils.DropTable(kTableGroupsWords);
     DaoUtils.DropTable(kTableGroup);
 }
 //--------------------------------------------------------------------------
 // used to export to xml
 public static void FillDataSet(DataSet ds)
 {
     DaoUtils.FillDataSet(kSQLSelectAll, kTableGroup.Replace("`", ""), ds);
     DaoUtils.FillDataSet(kSQLSelectAllGroupWords,
                          kTableGroupsWords.Replace("`", ""), ds);
 }
Beispiel #7
0
 //--------------------------------------------------------------------------
 public static void CreateTable()
 {
     DaoUtils.ExecuteNonQuery(kSQLCreateTable);
 }
Beispiel #8
0
 //--------------------------------------------------------------------------
 public static void DropTable()
 {
     DaoUtils.DropTable(kTableWord);
 }
Beispiel #9
0
 //--------------------------------------------------------------------------
 // used to export to xml
 public static void FillDataSet(DataSet ds)
 {
     DaoUtils.FillDataSet(kSQLSelectAll, kTableWord, ds);
 }
Beispiel #10
0
 //--------------------------------------------------------------------------
 public static void DropTable()
 {
     DaoUtils.DropTable(kTableDocument);
 }
Beispiel #11
0
 //--------------------------------------------------------------------------
 public static void DropTable()
 {
     DaoUtils.DropTable(kTableContains);
 }
 //--------------------------------------------------------------------------
 public static void DropTable()
 {
     DaoUtils.DropTable(kTablePhrasesWords);
     DaoUtils.DropTable(kTablePhrase);
 }
 //--------------------------------------------------------------------------
 public static void CreateTable()
 {
     DaoUtils.ExecuteNonQuery(kSQLCreateTablePhrase);
     DaoUtils.ExecuteNonQuery(kSQLCreateTablePhrasesWords);
 }
 //--------------------------------------------------------------------------
 public static void CreateTable()
 {
     DaoUtils.ExecuteNonQuery(kSQLCreateTableRelation);
     DaoUtils.ExecuteNonQuery(kSQLCreateTableRelationsWords);
 }
 //--------------------------------------------------------------------------
 public static void DropTable()
 {
     DaoUtils.DropTable(kTableRelationsWords);
     DaoUtils.DropTable(kTableRelation);
 }