Faster stat processing

This commit is contained in:
Michael Simard
2020-11-16 07:48:21 -06:00
parent aeb6b16afb
commit 8d94b42439
6 changed files with 213 additions and 38 deletions

View File

@@ -26,17 +26,22 @@ struct DataPoint : Content {
final class AllStats: Content {
var overall:Stats
var mwStats:Stats
var bocwStats:Stats
var byMonth: [MonthStats]
var highestWinLossRatio:String
var dataPoints:[DataPoint]
var mostRecentRecord:String
init( overall:Stats, byMonth:[MonthStats], highestWinLossRatio:String, dataPoints:[DataPoint], mostRecentRecord:String) {
init( overall:Stats, mwStats:Stats, bocwStats:Stats, byMonth:[MonthStats], highestWinLossRatio:String, dataPoints:[DataPoint], mostRecentRecord:String) {
self.overall = overall
self.byMonth = byMonth
self.highestWinLossRatio = highestWinLossRatio
self.dataPoints = dataPoints
self.mostRecentRecord = mostRecentRecord
self.mwStats = mwStats;
self.bocwStats = bocwStats;
}
}