Files
git.stella-ops.org/src/Scanner/__Libraries/StellaOps.Scanner.ChangeTrace/ByteDiff/IByteLevelDiffer.cs
2026-01-12 12:24:17 +02:00

31 lines
903 B
C#

// Copyright (c) StellaOps. All rights reserved.
// Licensed under AGPL-3.0-or-later. See LICENSE in the project root.
using StellaOps.Scanner.ChangeTrace.Models;
namespace StellaOps.Scanner.ChangeTrace.ByteDiff;
/// <summary>
/// Service for byte-level binary comparison using rolling hash windows.
/// </summary>
public interface IByteLevelDiffer
{
/// <summary>
/// Compare two binary files and return byte-level deltas.
/// </summary>
Task<IReadOnlyList<ByteDelta>> CompareAsync(
Stream fromStream,
Stream toStream,
ByteDiffOptions? options = null,
CancellationToken ct = default);
/// <summary>
/// Compare two binary files by path.
/// </summary>
Task<IReadOnlyList<ByteDelta>> CompareFilesAsync(
string fromPath,
string toPath,
ByteDiffOptions? options = null,
CancellationToken ct = default);
}