2019-10-06 21:58:36 +00:00
|
|
|
|
using System;
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
using System.IO;
|
2020-08-11 14:24:47 +00:00
|
|
|
|
using System.Text;
|
2020-04-20 21:36:33 +00:00
|
|
|
|
using System.Threading.Tasks;
|
2020-03-23 12:57:18 +00:00
|
|
|
|
using Wabbajack.Common;
|
2019-10-06 21:58:36 +00:00
|
|
|
|
|
2020-06-27 17:04:59 +00:00
|
|
|
|
namespace Compression.BSA
|
2019-10-06 21:58:36 +00:00
|
|
|
|
{
|
|
|
|
|
public interface IFile
|
|
|
|
|
{
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// The path of the file inside the archive
|
|
|
|
|
/// </summary>
|
2020-03-23 12:57:18 +00:00
|
|
|
|
RelativePath Path { get; }
|
2019-10-06 21:58:36 +00:00
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// The uncompressed file size
|
|
|
|
|
/// </summary>
|
|
|
|
|
uint Size { get; }
|
|
|
|
|
|
2019-10-07 22:13:38 +00:00
|
|
|
|
/// <summary>
|
|
|
|
|
/// Get the metadata for the file.
|
|
|
|
|
/// </summary>
|
|
|
|
|
FileStateObject State { get; }
|
|
|
|
|
|
2019-10-06 21:58:36 +00:00
|
|
|
|
/// <summary>
|
|
|
|
|
/// Copies this entry to the given stream. 100% thread safe, the .bsa will be opened multiple times
|
|
|
|
|
/// in order to maintain thread-safe access.
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="output"></param>
|
2020-05-25 16:24:16 +00:00
|
|
|
|
ValueTask CopyDataTo(Stream output);
|
2020-05-02 20:15:36 +00:00
|
|
|
|
|
|
|
|
|
void Dump(Action<string> print);
|
2020-09-05 14:01:32 +00:00
|
|
|
|
ValueTask<IStreamFactory> GetStreamFactory();
|
2019-10-06 21:58:36 +00:00
|
|
|
|
}
|
|
|
|
|
}
|