[Quantproject-developers] QuantProject/b4_Business/a1_Financial/a3_Ordering HistoricalEndOfDayOrderE
Brought to you by:
glauco_1
|
From: Glauco S. <gla...@us...> - 2005-01-09 23:15:33
|
Update of /cvsroot/quantproject/QuantProject/b4_Business/a1_Financial/a3_Ordering In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv8783/b4_Business/a1_Financial/a3_Ordering Modified Files: HistoricalEndOfDayOrderExecutor.cs Log Message: - the IHistoricalQuoteProvider "concept" has been introduced Index: HistoricalEndOfDayOrderExecutor.cs =================================================================== RCS file: /cvsroot/quantproject/QuantProject/b4_Business/a1_Financial/a3_Ordering/HistoricalEndOfDayOrderExecutor.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** HistoricalEndOfDayOrderExecutor.cs 13 Dec 2004 01:44:42 -0000 1.2 --- HistoricalEndOfDayOrderExecutor.cs 9 Jan 2005 23:15:21 -0000 1.3 *************** *** 25,28 **** --- 25,29 ---- using QuantProject.Data.DataProviders; + using QuantProject.Business.DataProviders; using QuantProject.Business.Financial.Accounting; using QuantProject.Business.Financial.Accounting.Transactions; *************** *** 38,45 **** { private IEndOfDayTimer timer; ! public HistoricalEndOfDayOrderExecutor( IEndOfDayTimer timer ) { this.timer = timer; } --- 39,49 ---- { private IEndOfDayTimer timer; + private IHistoricalQuoteProvider historicalQuoteProvider; ! public HistoricalEndOfDayOrderExecutor( IEndOfDayTimer timer , ! IHistoricalQuoteProvider historicalQuoteProvider ) { this.timer = timer; + this.historicalQuoteProvider = historicalQuoteProvider; } *************** *** 49,55 **** public void Execute( Order order ) { ! double instrumentPrice = HistoricalDataProvider.GetMarketValue( order.Instrument.Key , ! this.timer.GetCurrentTime().DateTime , ! this.timer.GetCurrentTime().GetNearestBarComponent() ); EndOfDayTransaction endOfDayTransaction = new EndOfDayTransaction( TimedTransaction.GetTransactionType( order.Type ) , order.Instrument , --- 53,58 ---- public void Execute( Order order ) { ! double instrumentPrice = this.historicalQuoteProvider.GetMarketValue( order.Instrument.Key , ! this.timer.GetCurrentTime() ); EndOfDayTransaction endOfDayTransaction = new EndOfDayTransaction( TimedTransaction.GetTransactionType( order.Type ) , order.Instrument , |