This commit is contained in:
2024-02-22 14:52:53 -05:00
parent 72c94666c5
commit 29b417e3f7
445 changed files with 360852 additions and 0 deletions

View File

@@ -0,0 +1,28 @@
using System;
using System.Collections.Generic;
using System.Collections;
using System.Text;
namespace MarketData.Utils
{
public class DateRange : List<DateTime>
{
public DateRange(DateTime startDate,DateTime endDate)
{
startDate = startDate.Date;
endDate=endDate.Date;
DateGenerator dateGenerator=new DateGenerator();
List<DateTime> dates= dateGenerator.GenerateHistoricalDates(startDate, endDate);
foreach (DateTime date in dates) Add(date);
Sort(); // ensure that no matter how we set this up, the oldest date winds up being at the lowest index of the list
}
public DateTime StartDate
{
get { return this[0]; }
}
public DateTime EndDate
{
get { return this[Count-1]; }
}
}
}