37 lines
974 B
C#
37 lines
974 B
C#
using System.Collections.Generic;
|
|
|
|
namespace Tornado3_2026Election.Domain;
|
|
|
|
public sealed class FormatTemplateDefinition
|
|
{
|
|
public required string Id { get; init; }
|
|
|
|
public required string Name { get; init; }
|
|
|
|
public required string Description { get; init; }
|
|
|
|
public required BroadcastChannel RecommendedChannel { get; init; }
|
|
|
|
public required bool RequiresImage { get; init; }
|
|
|
|
public required bool SupportsPreElection { get; init; }
|
|
|
|
public required bool SupportsCounting { get; init; }
|
|
|
|
public required bool RequiresCandidateData { get; init; }
|
|
|
|
public required LoopMode LoopMode { get; init; }
|
|
|
|
public required IReadOnlyList<FormatCutDefinition> Cuts { get; init; }
|
|
|
|
public bool IsAvailableInPhase(BroadcastPhase phase)
|
|
{
|
|
return phase switch
|
|
{
|
|
BroadcastPhase.PreElection => SupportsPreElection,
|
|
BroadcastPhase.Counting => SupportsCounting,
|
|
_ => false
|
|
};
|
|
}
|
|
}
|