// SPDX-FileCopyrightText: 2026 FocusFlow contributors
// SPDX-License-Identifier: AGPL-3.0-only

part of '../free_slots.dart';

/// Typed overlap between an explicitly placed required commitment and rest.
class ProtectedFreeSlotConflict {
  /// Creates a `ProtectedFreeSlotConflict` instance with the values required by its invariants.
  /// Callers should pass already-normalized scheduler data because validation and defaulting belong at the model or service boundary, not in arbitrary UI code.
  const ProtectedFreeSlotConflict({
    required this.requiredTaskId,
    required this.freeSlotTaskId,
    required this.requiredInterval,
    required this.freeSlotInterval,
  });

  /// Critical or inflexible task that was explicitly placed.
  final String requiredTaskId;

  /// Protected Free Slot task that was interrupted.
  final String freeSlotTaskId;

  /// Required commitment interval.
  final TimeInterval requiredInterval;

  /// Protected rest interval.
  final TimeInterval freeSlotInterval;
}
