/// <summary> /// Read all disks. /// </summary> /// <param name="fs">Target filesystem.</param> public static MochaReader <MochaDisk> ReadDisks(this MochaFileSystem fs) => new MochaReader <MochaDisk>(fs.GetDisks());
/// <summary> /// Read all disks. /// </summary> /// <param name="fs">Target filesystem.</param> /// <param name="query">Query for filtering.</param> public static MochaReader <MochaDisk> ReadDisks(this MochaFileSystem fs, Func <MochaDisk, bool> query) => new MochaReader <MochaDisk>(fs.GetDisks().Where(query));
/// <summary> /// Return all disks. /// </summary> /// <param name="fs">Target filesystem.</param> /// <param name="query">Query for filtering.</param> public static MochaCollectionResult <MochaDisk> GetDisks(this MochaFileSystem fs, Func <MochaDisk, bool> query) => new MochaCollectionResult <MochaDisk>(fs.GetDisks().Where(query));