From e6c3278b61ef90e8c6a7b1118a801f872b40311b Mon Sep 17 00:00:00 2001 From: Natalia Portillo Date: Sun, 12 Oct 2025 15:16:35 +0100 Subject: [PATCH] [AaruFormat] Implement SetTape. --- Aaru.Images/AaruFormat/Tape.cs | 14 +++++++++++++- Aaru.Images/AaruFormat/Unimplemented.cs | 5 ----- 2 files changed, 13 insertions(+), 6 deletions(-) diff --git a/Aaru.Images/AaruFormat/Tape.cs b/Aaru.Images/AaruFormat/Tape.cs index 505198dd1..7711260c4 100644 --- a/Aaru.Images/AaruFormat/Tape.cs +++ b/Aaru.Images/AaruFormat/Tape.cs @@ -43,6 +43,17 @@ public sealed partial class AaruFormat return res == Status.Ok; } + /// + public bool IsTape { get; private set; } + + /// + public bool SetTape() + { + IsTape = true; + + return true; + } + #endregion // AARU_EXPORT int32_t AARU_CALL aaruf_set_tape_file(void *context, const uint8_t partition, const uint32_t file, @@ -51,7 +62,8 @@ public sealed partial class AaruFormat [UnmanagedCallConv(CallConvs = [typeof(CallConvStdcall)])] private static partial Status aaruf_set_tape_file(IntPtr context, byte partition, uint file, ulong startingBlock, ulong endingBlock); - // AARU_EXPORT int32_t AARU_CALL aaruf_set_tape_partition(void *context, const uint8_t partition, + + // AARU_EXPORT int32_t AARU_CALL aaruf_set_tape_partition(void *context, const uint8_t partition, // const uint64_t starting_block, const uint64_t ending_block) [LibraryImport("libaaruformat", EntryPoint = "aaruf_set_tape_partition", SetLastError = true)] [UnmanagedCallConv(CallConvs = [typeof(CallConvStdcall)])] diff --git a/Aaru.Images/AaruFormat/Unimplemented.cs b/Aaru.Images/AaruFormat/Unimplemented.cs index 7814d74bb..970c89ce7 100644 --- a/Aaru.Images/AaruFormat/Unimplemented.cs +++ b/Aaru.Images/AaruFormat/Unimplemented.cs @@ -34,11 +34,6 @@ public sealed partial class AaruFormat public List Files { get; } /// public List TapePartitions { get; } - /// - public bool IsTape { get; } - - /// - public bool SetTape() => throw new NotImplementedException(); #endregion } \ No newline at end of file