示例#1
0
        /// <summary>
        ///     Check that the list of author names matches the names of all author files
        ///     contained in the bookList  Authors directory.
        /// </summary>
        public void UpdateAuthorsNamesWithFileNames()
        {
            this._msgBox.NameOfMethod = MethodBase.GetCurrentMethod().Name;

            var cls = new FileClass();

            cls.GetAuthorFileNamesFromAuthorsList();
            cls.GetAllAuthorFilePathsContainedInAuthorDirectory();
            this.GetAuthorFileNamesAddToAuthorsNamesList();
        }
示例#2
0
        /// <summary>
        ///     Searches the book title all authors.
        /// </summary>
        public void SearchBookAuthorAllTitles()
        {
            this._msgBox.NameOfMethod = MethodBase.GetCurrentMethod().Name;

            var cls1 = new FileClass();

            cls1.GetAllAuthorFilePathsContainedInAuthorDirectory();

            var coll1 = new BookDataCollection();

            coll1.ClearCollection();

            this.AuthorNamesSearchLoop();


            var coll2 = new BookTitlesCollection();

            if (coll2.GetItemsCount() < 1)
            {
                coll2.AddItem("No titles with this search criteria were found.");
            }
        }