2016-06-10 01:38:58 -07:00
|
|
|
|
using System;
|
|
|
|
|
|
using System.Collections.Generic;
|
2016-05-16 11:59:33 -07:00
|
|
|
|
|
|
|
|
|
|
namespace SabreTools.Helper
|
2016-04-12 15:03:47 -07:00
|
|
|
|
{
|
2016-08-29 14:43:31 -07:00
|
|
|
|
#region Skipper structs
|
|
|
|
|
|
|
2016-06-16 22:17:58 -07:00
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// Intermediate struct for holding header skipper information
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
public struct Skipper
|
|
|
|
|
|
{
|
|
|
|
|
|
public string Name;
|
|
|
|
|
|
public string Author;
|
|
|
|
|
|
public string Version;
|
|
|
|
|
|
public List<SkipperRule> Rules;
|
2016-09-22 21:32:06 -07:00
|
|
|
|
public string SourceFile;
|
2016-06-16 22:17:58 -07:00
|
|
|
|
}
|
|
|
|
|
|
|
2016-06-16 19:36:05 -07:00
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// Intermediate struct for holding header skipper rule information
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
public struct SkipperRule
|
|
|
|
|
|
{
|
2016-06-16 22:17:58 -07:00
|
|
|
|
public long? StartOffset; // null is EOF
|
|
|
|
|
|
public long? EndOffset; // null if EOF
|
|
|
|
|
|
public HeaderSkipOperation Operation;
|
|
|
|
|
|
public List<SkipperTest> Tests;
|
2016-09-22 21:32:06 -07:00
|
|
|
|
public string SourceFile;
|
2016-06-16 19:36:05 -07:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// Intermediate struct for holding header test information
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
public struct SkipperTest
|
|
|
|
|
|
{
|
2016-06-16 22:17:58 -07:00
|
|
|
|
public HeaderSkipTest Type;
|
|
|
|
|
|
public long? Offset; // null is EOF
|
|
|
|
|
|
public byte[] Value;
|
|
|
|
|
|
public bool Result;
|
|
|
|
|
|
public byte[] Mask;
|
|
|
|
|
|
public long? Size; // null is PO2, "power of 2" filesize
|
|
|
|
|
|
public HeaderSkipTestFileOperator Operator;
|
2016-06-16 19:36:05 -07:00
|
|
|
|
}
|
2016-08-29 14:43:31 -07:00
|
|
|
|
|
|
|
|
|
|
#endregion
|
2016-04-12 15:03:47 -07:00
|
|
|
|
}
|