[Xia] Implement GetAttributes.

This commit is contained in:
2026-02-03 20:36:06 +00:00
parent 19253ea67b
commit d67b4d9938
2 changed files with 17 additions and 4 deletions

View File

@@ -40,6 +40,23 @@ namespace Aaru.Filesystems;
/// <inheritdoc />
public sealed partial class Xia
{
/// <inheritdoc />
public ErrorNumber GetAttributes(string path, out FileAttributes attributes)
{
attributes = FileAttributes.None;
if(!_mounted) return ErrorNumber.AccessDenied;
// Use Stat to get file info including attributes
ErrorNumber errno = Stat(path, out FileEntryInfo stat);
if(errno != ErrorNumber.NoError) return errno;
attributes = stat.Attributes;
return ErrorNumber.NoError;
}
/// <inheritdoc />
public ErrorNumber Stat(string path, out FileEntryInfo stat)
{

View File

@@ -49,10 +49,6 @@ public sealed partial class Xia
/// <inheritdoc />
public ErrorNumber Unmount() => throw new NotImplementedException();
/// <inheritdoc />
public ErrorNumber GetAttributes(string path, out FileAttributes attributes) => throw new NotImplementedException();
/// <inheritdoc />
public ErrorNumber StatFs(out FileSystemInfo stat) => throw new NotImplementedException();