Package com.opengamma.financial.analytics.conversion

Examples of com.opengamma.financial.analytics.conversion.BondTradeConverter.convert()


    final Trade trade = target.getTrade();
    final HolidaySource holidaySource = OpenGammaExecutionContext.getHolidaySource(context);
    final ConventionBundleSource conventionSource = OpenGammaExecutionContext.getConventionBundleSource(context);
    final RegionSource regionSource = OpenGammaExecutionContext.getRegionSource(context);
    BondTradeConverter visitor = new BondTradeConverter(new BondSecurityConverter(holidaySource, conventionSource, regionSource));
    final BondFixedTransactionDefinition definition = visitor.convert(trade);
    BondFixedTransaction derivative = definition.toDerivative(date, riskFreeCurveName, creditCurveName);
    return CALCULATOR.presentValueFromCleanPrice(derivative, data, price);
  }

}
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.