using System.Collections.Generic;
using System.Threading;
using OpenNest.Geometry;
namespace OpenNest
{
///
/// Result of a nest optimization run.
///
public class NestResult
{
///
/// The best sequence found: (drawingId, rotation, drawing) tuples in placement order.
///
public List<(int drawingId, double rotation, Drawing drawing)> Sequence { get; set; }
///
/// The score achieved by the best sequence.
///
public FillScore Score { get; set; }
///
/// Number of iterations performed.
///
public int Iterations { get; set; }
}
///
/// Interface for nest optimization algorithms that search for the best
/// part ordering and rotation to maximize plate utilization.
///
public interface INestOptimizer
{
NestResult Optimize(List items, Box workArea, NfpCache cache,
Dictionary> candidateRotations,
CancellationToken cancellation = default);
}
}