public Set<ComputedValue> execute(final FunctionExecutionContext executionContext, final FunctionInputs inputs, final ComputationTarget target,
final Set<ValueRequirement> desiredValues) throws AsynchronousExecution {
final RegionSource regionSource = OpenGammaExecutionContext.getRegionSource(executionContext);
final OrganizationSource organizationSource = OpenGammaExecutionContext.getOrganizationSource(executionContext);
final HolidaySource holidaySource = OpenGammaExecutionContext.getHolidaySource(executionContext);
final SecuritySource securitySource = OpenGammaExecutionContext.getSecuritySource(executionContext);
final CreditDefaultSwapSecurityConverter converter = new CreditDefaultSwapSecurityConverter(holidaySource, regionSource, organizationSource);
final ZonedDateTime valuationTime = ZonedDateTime.now(executionContext.getValuationClock());
final CreditDefaultSwapSecurity security = (CreditDefaultSwapSecurity) target.getSecurity();
final Calendar calendar = new HolidaySourceCalendarAdapter(holidaySource, FinancialSecurityUtils.getCurrency(security));
LegacyVanillaCreditDefaultSwapDefinition cds = (LegacyVanillaCreditDefaultSwapDefinition) security.accept(converter);