Class CollectionOnDriveT<T>
- Namespace
- SunamoCollectionOnDrive
- Assembly
- SunamoCollectionOnDrive.dll
A generic collection that persists custom types to disk using a parser interface.
public sealed class CollectionOnDriveT<T> : CollectionOnDriveBase<T>, IList<T>, ICollection<T>, IReadOnlyList<T>, IReadOnlyCollection<T>, IEnumerable<T>, IList, ICollection, IEnumerable where T : IParserCollectionOnDrive
Type Parameters
TType that implements IParserCollectionOnDrive for serialization/deserialization.
- Inheritance
-
List<T>CollectionOnDriveT<T>
- Implements
-
IList<T>ICollection<T>IEnumerable<T>
- Inherited Members
- Extension Methods
Constructors
CollectionOnDriveT(ILogger)
Initializes a new instance of the CollectionOnDriveT class.
public CollectionOnDriveT(ILogger logger)
Parameters
loggerILoggerLogger instance for logging operations.
Methods
Load(bool)
Loads the collection from disk, creating instances of T and parsing each line.
public override Task Load(bool isRemovingDuplicates)
Parameters
isRemovingDuplicatesboolWhether to remove duplicate entries when loading.