Assembla home | Assembla project page
 

Changeset 200

Show
Ignore:
Timestamp:
05/29/08 20:37:51 (6 months ago)
Author:
snovik
Message:

Change: Optimisation of PricingEngine? interfaces

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/QLNet/QLNet/PricingEngine.cs

    r131 r200  
    3838    } 
    3939 
    40     public interface IGenericEngine<ArgumentsType, ResultsType> : IPricingEngine, IObserver 
    41         where ArgumentsType : IPricingEngineArguments, new() 
    42         where ResultsType : IPricingEngineResults, new() { 
    43     } 
     40    public interface IGenericEngine : IPricingEngine, IObserver { } 
    4441 
    4542    // template base class for option pricing engines 
    4643    // Derived engines only need to implement the <tt>calculate()</tt> method. 
    47     public abstract class GenericEngine<ArgumentsType, ResultsType> : IGenericEngine<ArgumentsType, ResultsType> 
     44    public abstract class GenericEngine<ArgumentsType, ResultsType> : IGenericEngine 
    4845        where ArgumentsType : IPricingEngineArguments, new() 
    4946        where ResultsType : IPricingEngineResults, new() 
  • trunk/QLNet/QLNet/Pricingengines/vanilla/FDEuropeanEngine.cs

    r158 r200  
    2929              checking it against analytic results. 
    3030    */ 
    31     public class FDEuropeanEngine : FDVanillaEngine, IGenericEngine<OneAssetOption.Arguments, OneAssetOption.Results>
     31    public class FDEuropeanEngine : FDVanillaEngine, IGenericEngine
    3232        private SampledCurve prices_; 
    3333 
  • trunk/QLNet/QLNet/Pricingengines/vanilla/FDVanillaEngine.cs

    r165 r200  
    160160    } 
    161161 
    162     public class FDEngineAdapter<Base, Engine, ArgumentsType, ResultsType> 
    163         : FDVanillaEngine, IGenericEngine<ArgumentsType, ResultsType> 
     162    public class FDEngineAdapter<Base, Engine, ArgumentsType, ResultsType> : FDVanillaEngine, IGenericEngine 
    164163        where Base : FDConditionEngineTemplate, new() 
    165         where Engine : IGenericEngine<ArgumentsType, ResultsType> 
     164        where Engine : IGenericEngine 
    166165        where ArgumentsType : IPricingEngineArguments, new() 
    167166        where ResultsType : IPricingEngineResults, new() { 
  • trunk/QLNet/QLNet/Pricingengines/vanilla/fdbermudanengine.cs

    r166 r200  
    2525    //! Finite-differences Bermudan engine 
    2626    /*! \ingroup vanillaengines */ 
    27     public class FDBermudanEngine : FDMultiPeriodEngine, IGenericEngine<OneAssetOption.Arguments, OneAssetOption.Results>
     27    public class FDBermudanEngine : FDMultiPeriodEngine, IGenericEngine
    2828        protected double extraTermInBermudan; 
    2929 
  • trunk/QLNet/QLNet/Pricingengines/vanilla/mcvanillaengine.cs

    r197 r200  
    3535    } 
    3636 
    37     public abstract class MCVanillaEngine<MC, RNG, S, Inst> : McSimulation<MC, RNG, S>, 
    38             IGenericEngine<OneAssetOption.Arguments, OneAssetOption.Results> 
     37    public abstract class MCVanillaEngine<MC, RNG, S, Inst> : McSimulation<MC, RNG, S>, IGenericEngine 
    3938            where RNG : IRSG, new() where S : IGeneralStatistics, new() { 
    4039        //typedef typename McSimulation<MC,RNG,S>::path_generator_type path_generator_type;