Move RomFs

This commit is contained in:
Alex Barney 2021-12-18 19:49:31 -07:00
parent aa153980be
commit 34faf2b468
13 changed files with 31 additions and 28 deletions

View File

@ -1,7 +1,7 @@
using LibHac.Common; using LibHac.Common;
using LibHac.Fs; using LibHac.Fs;
using LibHac.Fs.Fsa; using LibHac.Fs.Fsa;
using LibHac.FsSystem.RomFs; using LibHac.Tools.FsSystem.RomFs;
namespace LibHac.FsSrv.FsCreator; namespace LibHac.FsSrv.FsCreator;

View File

@ -10,8 +10,8 @@ using LibHac.Diag;
using LibHac.Fs; using LibHac.Fs;
using LibHac.Fs.Fsa; using LibHac.Fs.Fsa;
using LibHac.FsSystem; using LibHac.FsSystem;
using LibHac.FsSystem.RomFs;
using LibHac.Spl; using LibHac.Spl;
using LibHac.Tools.FsSystem.RomFs;
namespace LibHac.Tools.FsSystem.NcaUtils; namespace LibHac.Tools.FsSystem.NcaUtils;

View File

@ -6,7 +6,7 @@
using System; using System;
using System.Diagnostics; using System.Diagnostics;
namespace LibHac; namespace LibHac.Tools.FsSystem.RomFs;
internal static class HashHelpers internal static class HashHelpers
{ {

View File

@ -2,9 +2,10 @@
using System.Runtime.InteropServices; using System.Runtime.InteropServices;
using LibHac.Common; using LibHac.Common;
using LibHac.Fs; using LibHac.Fs;
using LibHac.FsSystem;
using LibHac.Util; using LibHac.Util;
namespace LibHac.FsSystem.RomFs; namespace LibHac.Tools.FsSystem.RomFs;
/// <summary> /// <summary>
/// Represents the file table used by the RomFS format. /// Represents the file table used by the RomFS format.

View File

@ -5,9 +5,10 @@ using System.Linq;
using LibHac.Common; using LibHac.Common;
using LibHac.Fs; using LibHac.Fs;
using LibHac.Fs.Fsa; using LibHac.Fs.Fsa;
using LibHac.FsSystem;
using LibHac.Util; using LibHac.Util;
namespace LibHac.FsSystem.RomFs; namespace LibHac.Tools.FsSystem.RomFs;
/// <summary> /// <summary>
/// Builds a RomFS from a collection of files. /// Builds a RomFS from a collection of files.

View File

@ -3,9 +3,10 @@ using System.Collections.Generic;
using System.Runtime.CompilerServices; using System.Runtime.CompilerServices;
using System.Runtime.InteropServices; using System.Runtime.InteropServices;
using LibHac.Fs; using LibHac.Fs;
using LibHac.FsSystem;
using LibHac.Util; using LibHac.Util;
namespace LibHac.FsSystem.RomFs; namespace LibHac.Tools.FsSystem.RomFs;
internal class RomFsDictionary<T> where T : unmanaged internal class RomFsDictionary<T> where T : unmanaged
{ {

View File

@ -2,9 +2,10 @@
using System.Text; using System.Text;
using LibHac.Fs; using LibHac.Fs;
using LibHac.Fs.Fsa; using LibHac.Fs.Fsa;
using LibHac.FsSystem;
using LibHac.Util; using LibHac.Util;
namespace LibHac.FsSystem.RomFs; namespace LibHac.Tools.FsSystem.RomFs;
public class RomFsDirectory : IDirectory public class RomFsDirectory : IDirectory
{ {

View File

@ -1,7 +1,7 @@
using System; using System;
using System.Runtime.InteropServices; using System.Runtime.InteropServices;
namespace LibHac.FsSystem.RomFs; namespace LibHac.Tools.FsSystem.RomFs;
internal ref struct RomEntryKey internal ref struct RomEntryKey
{ {
@ -32,9 +32,7 @@ internal ref struct RomEntryKey
} }
} }
// todo: Change constraint to "unmanaged" after updating to internal ref struct RomKeyValuePair<T> where T : unmanaged
// a newer SDK https://github.com/dotnet/csharplang/issues/1937
internal ref struct RomKeyValuePair<T> where T : struct
{ {
public RomEntryKey Key; public RomEntryKey Key;
public int Offset; public int Offset;

View File

@ -3,7 +3,7 @@ using LibHac.Common;
using LibHac.Fs; using LibHac.Fs;
using LibHac.Fs.Fsa; using LibHac.Fs.Fsa;
namespace LibHac.FsSystem.RomFs; namespace LibHac.Tools.FsSystem.RomFs;
public class RomFsFile : IFile public class RomFsFile : IFile
{ {

View File

@ -2,8 +2,9 @@
using LibHac.Common; using LibHac.Common;
using LibHac.Fs; using LibHac.Fs;
using LibHac.Fs.Fsa; using LibHac.Fs.Fsa;
using LibHac.FsSystem;
namespace LibHac.FsSystem.RomFs; namespace LibHac.Tools.FsSystem.RomFs;
public class RomFsFileSystem : IFileSystem public class RomFsFileSystem : IFileSystem
{ {

View File

@ -1,7 +1,7 @@
using System.IO; using System.IO;
using LibHac.Fs; using LibHac.Fs;
using LibHac.FsSystem; using LibHac.FsSystem;
using LibHac.FsSystem.RomFs; using LibHac.Tools.FsSystem.RomFs;
namespace hactoolnet; namespace hactoolnet;

View File

@ -1,7 +1,7 @@
using System.IO; using System.IO;
using LibHac.Fs; using LibHac.Fs;
using LibHac.FsSystem; using LibHac.FsSystem;
using LibHac.FsSystem.RomFs; using LibHac.Tools.FsSystem.RomFs;
namespace hactoolnet; namespace hactoolnet;

View File

@ -1,5 +1,5 @@
using System; using System;
using LibHac.FsSystem.RomFs; using LibHac.Tools.FsSystem.RomFs;
using Xunit; using Xunit;
namespace LibHac.Tests; namespace LibHac.Tests;