using System.Collections.Generic; namespace Minesweeper.Core { public readonly struct BoardActionResult { public BoardActionResult(bool changed, bool hitMine, bool won, bool invalid, IReadOnlyList changedCells = null) { Changed = changed; HitMine = hitMine; Won = won; Invalid = invalid; ChangedCells = changedCells; } public bool Changed { get; } public bool HitMine { get; } public bool Won { get; } public bool Invalid { get; } public IReadOnlyList ChangedCells { get; } public static BoardActionResult NoChange => new BoardActionResult(false, false, false, false); public static BoardActionResult InvalidAction => new BoardActionResult(false, false, false, true); } }