Move wrapper interfaces to better namespace

This commit is contained in:
Matt Nadareski
2025-09-26 15:20:49 -04:00
parent 6035c19f47
commit 0e67f0bff4
38 changed files with 9 additions and 43 deletions

View File

@@ -99,8 +99,8 @@ Below is a table representing the various non-conversion interfaces that are imp
| Interface Name | Purpose |
| --- | --- |
| `SabreTools.Data.Printers.IPrinter` | Provides a formatted output for a model |
| `SabreTools.Serialization.Interfaces.IExtractable` | Marks a wrapper as able to be extracted |
| `SabreTools.Serialization.Interfaces.IWrapper` / `SabreTools.Serialization.Interfaces.IWrapper<T>` | Wraps a model or set of models to provide additional functionality |
| `SabreTools.Serialization.Wrappers.IExtractable` | Marks a wrapper as able to be extracted |
| `SabreTools.Serialization.Wrappers.IWrapper` / `SabreTools.Serialization.Wrappers.IWrapper<T>` | Wraps a model or set of models to provide additional functionality |
## Namespaces

View File

@@ -1,7 +1,6 @@
using System;
using System.Text;
using SabreTools.Data.Printers;
using SabreTools.Serialization.Interfaces;
using Wrapper = SabreTools.Serialization.Wrappers;
namespace SabreTools.Serialization
@@ -15,7 +14,7 @@ namespace SabreTools.Serialization
/// Print the item information from a wrapper to console as
/// pretty-printed text
/// </summary>
public static void PrintToConsole(this IWrapper wrapper)
public static void PrintToConsole(this Wrapper.IWrapper wrapper)
{
var sb = wrapper.ExportStringBuilder();
if (sb == null)
@@ -30,7 +29,7 @@ namespace SabreTools.Serialization
/// <summary>
/// Export the item information as a StringBuilder
/// </summary>
public static StringBuilder? ExportStringBuilder(this IWrapper wrapper)
public static StringBuilder? ExportStringBuilder(this Wrapper.IWrapper wrapper)
{
return wrapper switch
{
@@ -85,7 +84,7 @@ namespace SabreTools.Serialization
/// <summary>
/// Export the item information as JSON
/// </summary>
public static string ExportJSON(this IWrapper wrapper)
public static string ExportJSON(this Wrapper.IWrapper wrapper)
{
return wrapper switch
{

View File

@@ -1,7 +1,6 @@
using System;
using System.IO;
using SabreTools.IO.Extensions;
using SabreTools.Serialization.Interfaces;
using SabreTools.Serialization.Wrappers;
namespace SabreTools.Serialization

View File

@@ -1,7 +1,6 @@
using System;
using System.IO;
using SabreTools.IO.Compression.Deflate;
using SabreTools.Serialization.Interfaces;
namespace SabreTools.Serialization.Wrappers
{

View File

@@ -1,7 +1,6 @@
using System;
using System.IO;
using SabreTools.Data.Models.BSP;
using SabreTools.Serialization.Interfaces;
namespace SabreTools.Serialization.Wrappers
{

View File

@@ -1,7 +1,6 @@
using System;
using System.IO;
using SabreTools.IO.Compression.BZip2;
using SabreTools.Serialization.Interfaces;
namespace SabreTools.Serialization.Wrappers
{

View File

@@ -5,7 +5,6 @@ using SabreTools.Data.Models.CFB;
#if NETFRAMEWORK || NETSTANDARD
using SabreTools.IO.Extensions;
#endif
using SabreTools.Serialization.Interfaces;
namespace SabreTools.Serialization.Wrappers
{

View File

@@ -1,7 +1,6 @@
using System;
using System.Collections.Generic;
using System.IO;
using SabreTools.Serialization.Interfaces;
namespace SabreTools.Serialization.Wrappers
{

View File

@@ -2,7 +2,6 @@ using System;
using System.IO;
using SabreTools.Data.Models.GZIP;
using SabreTools.IO.Compression.Deflate;
using SabreTools.Serialization.Interfaces;
namespace SabreTools.Serialization.Wrappers
{

View File

@@ -1,4 +1,4 @@
namespace SabreTools.Serialization.Interfaces
namespace SabreTools.Serialization.Wrappers
{
/// <summary>
/// Represents an item that is extractable

View File

@@ -1,4 +1,4 @@
namespace SabreTools.Serialization.Interfaces
namespace SabreTools.Serialization.Wrappers
{
/// <summary>
/// Represents a wrapper around a top-level model

View File

@@ -1,4 +1,4 @@
namespace SabreTools.Serialization.Interfaces
namespace SabreTools.Serialization.Wrappers
{
/// <summary>
/// Represents a wrapper around a top-level model

View File

@@ -1,7 +1,6 @@
using System;
using System.IO;
using SabreTools.IO.Compression.Blast;
using SabreTools.Serialization.Interfaces;
namespace SabreTools.Serialization.Wrappers
{

View File

@@ -4,12 +4,11 @@ using System.Text.RegularExpressions;
using SabreTools.Data.Models.InstallShieldCabinet;
using SabreTools.Hashing;
using SabreTools.IO.Compression.zlib;
using SabreTools.Serialization.Interfaces;
using static SabreTools.Data.Models.InstallShieldCabinet.Constants;
namespace SabreTools.Serialization.Wrappers
{
public partial class InstallShieldCabinet : WrapperBase<Cabinet>, IExtractable
public partial class InstallShieldCabinet : IExtractable
{
#region Extension Properties

View File

@@ -1,7 +1,6 @@
using System;
using System.IO;
using SabreTools.IO.Compression.SZDD;
using SabreTools.Serialization.Interfaces;
namespace SabreTools.Serialization.Wrappers
{

View File

@@ -1,7 +1,6 @@
using System;
using System.IO;
using SabreTools.IO.Compression.SZDD;
using SabreTools.Serialization.Interfaces;
namespace SabreTools.Serialization.Wrappers
{

View File

@@ -1,7 +1,6 @@
using System;
using System.IO;
using SabreTools.IO.Compression.SZDD;
using SabreTools.Serialization.Interfaces;
namespace SabreTools.Serialization.Wrappers
{

View File

@@ -2,7 +2,6 @@
using System.IO;
using SabreTools.Data.Models.MicrosoftCabinet;
using SabreTools.IO.Extensions;
using SabreTools.Serialization.Interfaces;
namespace SabreTools.Serialization.Wrappers
{

View File

@@ -1,5 +1,4 @@
using System;
using SabreTools.Serialization.Interfaces;
#if (NET452_OR_GREATER || NETCOREAPP) && (WINX86 || WINX64)
using System.IO;
using StormLibSharp;

View File

@@ -1,7 +1,6 @@
using System;
using System.IO;
using SabreTools.IO.Extensions;
using SabreTools.Serialization.Interfaces;
namespace SabreTools.Serialization.Wrappers
{

View File

@@ -1,6 +1,5 @@
using System;
using System.IO;
using SabreTools.Serialization.Interfaces;
namespace SabreTools.Serialization.Wrappers
{

View File

@@ -1,6 +1,5 @@
using System;
using System.IO;
using SabreTools.Serialization.Interfaces;
namespace SabreTools.Serialization.Wrappers
{

View File

@@ -2,7 +2,6 @@ using System;
using System.Collections.Generic;
using System.IO;
using System.Text.RegularExpressions;
using SabreTools.Serialization.Interfaces;
#if NET462_OR_GREATER || NETCOREAPP
using SharpCompress.Archives;
using SharpCompress.Archives.Zip;

View File

@@ -2,7 +2,6 @@
using System.IO;
using SabreTools.IO.Compression.zlib;
using SabreTools.IO.Extensions;
using SabreTools.Serialization.Interfaces;
namespace SabreTools.Serialization.Wrappers
{

View File

@@ -1,5 +1,4 @@
using System;
using SabreTools.Serialization.Interfaces;
namespace SabreTools.Serialization.Wrappers
{

View File

@@ -2,7 +2,6 @@ using System;
using System.Collections.Generic;
using System.IO;
using System.Text.RegularExpressions;
using SabreTools.Serialization.Interfaces;
#if NET462_OR_GREATER || NETCOREAPP
using SharpCompress.Archives;
using SharpCompress.Archives.Rar;

View File

@@ -2,7 +2,6 @@ using System;
using System.Collections.Generic;
using System.IO;
using SabreTools.IO.Compression.zlib;
using SabreTools.Serialization.Interfaces;
namespace SabreTools.Serialization.Wrappers
{

View File

@@ -2,7 +2,6 @@ using System;
using System.IO;
using SabreTools.Data.Models.SecuROM;
using SabreTools.Hashing;
using SabreTools.Serialization.Interfaces;
namespace SabreTools.Serialization.Wrappers
{

View File

@@ -2,7 +2,6 @@ using System;
using System.Collections.Generic;
using System.IO;
using System.Text.RegularExpressions;
using SabreTools.Serialization.Interfaces;
#if NET462_OR_GREATER || NETCOREAPP
using SharpCompress.Archives;
using SharpCompress.Archives.SevenZip;

View File

@@ -1,7 +1,6 @@
using System;
using System.IO;
using SabreTools.Data.Models.TAR;
using SabreTools.Serialization.Interfaces;
namespace SabreTools.Serialization.Wrappers
{

View File

@@ -1,7 +1,6 @@
using System;
using System.IO;
using SabreTools.Data.Models.BSP;
using SabreTools.Serialization.Interfaces;
namespace SabreTools.Serialization.Wrappers
{

View File

@@ -1,7 +1,6 @@
using System;
using System.IO;
using SabreTools.IO.Extensions;
using SabreTools.Serialization.Interfaces;
using static SabreTools.Data.Models.VPK.Constants;
namespace SabreTools.Serialization.Wrappers

View File

@@ -1,6 +1,5 @@
using System;
using System.IO;
using SabreTools.Serialization.Interfaces;
namespace SabreTools.Serialization.Wrappers
{

View File

@@ -3,7 +3,6 @@ using System.IO;
using SabreTools.Hashing;
using SabreTools.IO.Compression.Deflate;
using SabreTools.IO.Extensions;
using SabreTools.Serialization.Interfaces;
namespace SabreTools.Serialization.Wrappers
{

View File

@@ -2,7 +2,6 @@ using System;
using System.IO;
using SabreTools.IO.Extensions;
using SabreTools.IO.Streams;
using SabreTools.Serialization.Interfaces;
namespace SabreTools.Serialization.Wrappers
{

View File

@@ -1,5 +1,4 @@
using System.IO;
using SabreTools.Serialization.Interfaces;
namespace SabreTools.Serialization.Wrappers
{

View File

@@ -2,7 +2,6 @@ using System;
#if NET462_OR_GREATER || NETCOREAPP
using System.IO;
#endif
using SabreTools.Serialization.Interfaces;
#if NET462_OR_GREATER || NETCOREAPP
using SharpCompress.Compressors.Xz;
#endif

View File

@@ -1,6 +1,5 @@
using System;
using System.IO;
using SabreTools.Serialization.Interfaces;
namespace SabreTools.Serialization.Wrappers
{