/*
* 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.Securities.CurrencyConversion
{
///
/// Represents a type capable of calculating the conversion rate between two currencies
///
public interface ICurrencyConversion
{
///
/// Event fired when the conversion rate is updated
///
event EventHandler ConversionRateUpdated;
///
/// The currency this conversion converts from
///
string SourceCurrency { get; }
///
/// The currency this conversion converts to
///
string DestinationCurrency { get; }
///
/// The current conversion rate between and
///
decimal ConversionRate { get; set; }
///
/// The securities which the conversion rate is based on
///
IEnumerable ConversionRateSecurities { get; }
///
/// Updates the internal conversion rate based on the latest data, and returns the new conversion rate
///
/// The new conversion rate
void Update();
}
}