mirror of
https://github.com/danbulant/Cosmos
synced 2026-05-19 04:18:43 +00:00
28 lines
1 KiB
C#
28 lines
1 KiB
C#
using Cosmos.HAL.BlockDevice;
|
|
|
|
namespace Cosmos.System.FileSystem
|
|
{
|
|
public abstract class FileSystemFactory
|
|
{
|
|
/// <summary>
|
|
/// Get the name of the file system.
|
|
/// </summary>
|
|
public abstract string Name { get; }
|
|
|
|
/// <summary>
|
|
/// Checks if the file system can handle the partition.
|
|
/// </summary>
|
|
/// <param name="aDevice">The partition.</param>
|
|
/// <returns>Returns true if the file system can handle the partition, false otherwise.</returns>
|
|
public abstract bool IsType(Partition aDevice);
|
|
|
|
/// <summary>
|
|
/// Creates a new <see cref="FileSystem"/> object for the given partition, root path, and size.
|
|
/// </summary>
|
|
/// <param name="aDevice">The partition.</param>
|
|
/// <param name="aRootPath">The root path.</param>
|
|
/// <param name="aSize">The size, in MB.</param>
|
|
/// <returns>FileSystem value.</returns>
|
|
public abstract FileSystem Create(Partition aDevice, string aRootPath, long aSize);
|
|
}
|
|
}
|