FileSurfer 2.1.2
Cross-platform file manager with support for Git and SFTP
Loading...
Searching...
No Matches
FileSurfer.Linux.Models.FileInformation.LinuxFileInfoProvider Class Reference

Provides Linux-specific file system metadata such as drives, folders, and hidden-state checks. More...

Inheritance diagram for FileSurfer.Linux.Models.FileInformation.LinuxFileInfoProvider:
Collaboration diagram for FileSurfer.Linux.Models.FileInformation.LinuxFileInfoProvider:

Public Member Functions

 LinuxFileInfoProvider (IShellHandler shellHandler)
 Creates a Linux file info provider that queries shell tools for platform data.
override DriveEntryInfo[] GetDrives ()
 Gets an array of drives on the system.
override IEnumerable< string > GetSpecialFolders ()
 Retrieves special folder paths.
override bool IsHidden (string path, bool isDirectory)
 Checks if a path is hidden.
override string GetRoot ()
 Returns the root of the containing filesystem.
override bool IsLinkedToDirectory (string linkPath, out string directory)
Public Member Functions inherited from FileSurfer.Core.Models.FileInformation.LocalFileInfoProvider
bool IsLinkedToDirectory (string linkPath, [NotNullWhen(true)] out string? directory)
 Checks if a symbolic link is referring to a directory.
ValueResult< DirectoryContents > GetPathEntries (string path, bool includeHidden, bool includeOs)
 Gets files and directories in a directory, with optional inclusion of hidden and system entries.
async Task< ValueResult< DirectoryContents > > GetPathEntriesAsync (string path, bool includeHidden, bool includeOs, CancellationToken ct)
 Asynchronously gets files in a directory, with optional inclusion of hidden and system entries.
virtual ValueResult< Stream > GetFileStream (string path)
 Returns an opened file stream for reading on the specified path.
DateTime? GetFileLastWriteUtc (string filePath)
 Gets the last modified Utc time of a file.
Task< DateTime?> GetFileLastWriteUtcAsync (string filePath)
 Asynchronously gets the last modified Utc time of a file.
DateTime? GetDirLastWriteUtc (string dirPath)
 Gets the last modified Utc time of a directory.
virtual Task< DateTime?> GetDirLastWriteUtcAsync (string dirPath)
 Asynchronously gets the last modified Utc time of a directory.
bool IsHidden (string path, bool isDirectory)
 Checks if a path is hidden.
string GetRoot ()
 Returns the root of the containing filesystem.
ExistsInfo Exists (string path)
 Determines if the file or directory exists within the containing file system.
Task< ExistsInfo > ExistsAsync (string path)
 Asynchronously determines if the file or directory exists within the containing file system.
DriveEntryInfo[] GetDrives ()
 Gets an array of drives on the system.
IEnumerable< string > GetSpecialFolders ()
 Retrieves special folder paths.

Additional Inherited Members

Protected Member Functions inherited from FileSurfer.Core.Models.FileInformation.LocalFileInfoProvider
virtual bool IsOsProtected (string path, bool isDirectory)
 Determines whether a local path is protected by the operating system.
Properties inherited from FileSurfer.Core.Models.FileInformation.LocalFileInfoProvider
virtual IPathTools PathTools [get]
 Provides methods for manipulating paths for specific filesystems.

Detailed Description

Provides Linux-specific file system metadata such as drives, folders, and hidden-state checks.

Constructor & Destructor Documentation

◆ LinuxFileInfoProvider()

FileSurfer.Linux.Models.FileInformation.LinuxFileInfoProvider.LinuxFileInfoProvider ( IShellHandler shellHandler)
inline

Creates a Linux file info provider that queries shell tools for platform data.

Member Function Documentation

◆ GetDrives()

override DriveEntryInfo[] FileSurfer.Linux.Models.FileInformation.LinuxFileInfoProvider.GetDrives ( )
inline

Gets an array of drives on the system.

Returns
The available drives.

Implements FileSurfer.Core.Models.FileInformation.ILocalFileInfoProvider.

◆ GetRoot()

override string FileSurfer.Linux.Models.FileInformation.LinuxFileInfoProvider.GetRoot ( )
inline

Returns the root of the containing filesystem.

Returns
The filesystem root path.

Implements FileSurfer.Core.Models.FileInformation.IFileInfoProvider.

◆ GetSpecialFolders()

override IEnumerable< string > FileSurfer.Linux.Models.FileInformation.LinuxFileInfoProvider.GetSpecialFolders ( )
inline

Retrieves special folder paths.

Returns
A sequence of special folder paths.

Implements FileSurfer.Core.Models.FileInformation.ILocalFileInfoProvider.

◆ IsHidden()

override bool FileSurfer.Linux.Models.FileInformation.LinuxFileInfoProvider.IsHidden ( string path,
bool isDirectory )
inline

Checks if a path is hidden.

Parameters
pathThe path to evaluate.
isDirectorytrue when the path is a directory; otherwise it is treated as a file.
Returns
true if the path is hidden, otherwise false.

Implements FileSurfer.Core.Models.FileInformation.IFileInfoProvider.

◆ IsLinkedToDirectory()

override bool FileSurfer.Linux.Models.FileInformation.LinuxFileInfoProvider.IsLinkedToDirectory ( string linkPath,
out string directory )
inline

The documentation for this class was generated from the following file: