/* * QUANTCONNECT.COM - Democratizing Finance, Empowering Individuals. * Lean Algorithmic Trading Engine v2.0. Copyright 2014 QuantConnect Corporation. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ using System; using System.Collections.Generic; namespace QuantConnect { /// /// Enum lists available trading events /// public enum TradingDayType { /// /// Business day (0) /// BusinessDay, /// /// Public Holiday (1) /// PublicHoliday, /// /// Weekend (2) /// Weekend, /// /// Option Expiration Date (3) /// OptionExpiration, /// /// Futures Expiration Date (4) /// FutureExpiration, /// /// Futures Roll Date (5) /// /// Not used yet. For future use. FutureRoll, /// /// Symbol Delisting Date (6) /// /// Not used yet. For future use. SymbolDelisting, /// /// Equity Ex-dividend Date (7) /// /// Not used yet. For future use. EquityDividends, /// /// FX Economic Event (8) /// /// FX Economic Event e.g. from DailyFx (DailyFx.cs). Not used yet. For future use. EconomicEvent } /// /// Class contains trading events associated with particular day in /// public class TradingDay { /// /// The date that this instance is associated with /// public DateTime Date { get; internal set; } /// /// Property returns true, if the day is a business day /// public bool BusinessDay { get; internal set; } /// /// Property returns true, if the day is a public holiday /// public bool PublicHoliday { get; internal set; } /// /// Property returns true, if the day is a weekend /// public bool Weekend { get; internal set; } /// /// Property returns the list of options (among currently traded) that expire on this day /// public IEnumerable OptionExpirations { get; internal set; } /// /// Property returns the list of futures (among currently traded) that expire on this day /// public IEnumerable FutureExpirations { get; internal set; } /// /// Property returns the list of futures (among currently traded) that roll forward on this day /// /// Not used yet. For future use. public IEnumerable FutureRolls { get; internal set; } /// /// Property returns the list of symbols (among currently traded) that are delisted on this day /// /// Not used yet. For future use. public IEnumerable SymbolDelistings { get; internal set; } /// /// Property returns the list of symbols (among currently traded) that have ex-dividend date on this day /// /// Not used yet. For future use. public IEnumerable EquityDividends { get; internal set; } } }