using Nonemm.Core; namespace Nonemm.Contests; /// One contest's rules: what is exchanged, when a station may be worked again, /// what a contact scores and which multipliers it brings in. public interface Contest { /// The short name the log stores, e.g. `CQWW`. string Name { get; } string DisplayName { get; } /// The name the sponsor's Cabrillo header asks for. string CabrilloName { get; } /// The boxes the entry window shows. ARRL DX and others ask for a /// different exchange depending on where the operator is. IReadOnlyList ExchangeFieldsFor(StationInfo me); /// Up to three names, in the order the score summary shows them. IReadOnlyList MultiplierNames { get; } DupeScope DupeScope { get; } /// True when serial numbers count up across the whole contest rather than /// per band. bool HasSerialNumbers { get; } /// The modes the contest runs; empty means any. IReadOnlyList Modes { get; } string SentExchangeFor(StationInfo me); int PointsFor(QsoContext qso); /// False for a row in the log that is not a worked station. WAE keeps its /// QTC traffic in the log, and those rows score but are not contacts: they /// bring no multiplier and cannot be a dupe. bool IsContact(Qso qso) => true; IReadOnlyList MultipliersFor(QsoContext qso); int TotalScore(ScoreTally tally); /// The exchange columns of this contact's Cabrillo line. CabrilloExchange CabrilloExchange(Qso qso, StationInfo me); }