Esempio n. 1
0
        /// <summary>
        /// Check to see if the stored list of Entries written en masse
        /// contains an Entry or not.
        /// Can be used after a call to StoreEntryForWrite or RemoveStoredEntry to validate that
        /// the Entry was really added/removed.
        /// </summary>
        /// <param name="e"></param>
        /// <returns></returns>
        public bool ContainsStoredEntry(IEntry e)
        {
            delegateEntryIO delContainsStoredEntry =
                new delegateEntryIO(FileIOManager.ListContainsEntry);

            return(delContainsStoredEntry(e, fsi));
        }
Esempio n. 2
0
        /// <summary>
        /// Add an ini entry to a collection that can then be written all at once.
        /// </summary>
        /// <param name="e">
        /// Instance of an object from a class that implements
        /// the IEntry interface.  Entry to write.
        /// </param>
        /// <returns>
        /// True if the Entry was stored successfully, False if there was a problem.
        /// </returns>
        public bool StoreEntryForWrite(IEntry e)
        {
            delegateEntryIO delStoreEntry =
                new delegateEntryIO(FileIOManager.AddEntryToList);

            return(delStoreEntry(e, fsi));
        }
Esempio n. 3
0
        /// <summary>
        /// Remove an ini entry from the collection so it is not written to file.
        /// </summary>
        /// <returns>
        /// True if the Entry was removed from the stored list,
        /// False if there was a problem.
        /// </returns>
        public bool RemoveStoredEntry(IEntry e)
        {
            delegateEntryIO delRemoveStoredEntry =
                new delegateEntryIO(FileIOManager.RemoveEntryFromList);

            return(delRemoveStoredEntry(e, fsi));
        }
Esempio n. 4
0
        /// <summary>
        /// Write a Name/Value to a section.
        /// </summary>
        /// <param name="e">
        /// Instance of an object from a class that implements
        /// the IEntry interface.  Entry to write.
        /// </param>
        /// <returns>False if the write was unsucessful</returns>
        public bool WriteEntry(IEntry e)
        {
            delegateEntryIO delWriteEntry =
                new delegateEntryIO(FileIOManager.WriteEntry);

            return(delWriteEntry(e, fsi));
        }