Interface CreditRatesMarketDataLookup

  • All Superinterfaces:
    CalculationParameter

    public interface CreditRatesMarketDataLookup
    extends CalculationParameter
    The lookup that provides access to credit rates in market data.

    The credit rates market lookup provides access to credit, discount and recovery rate curves.

    The lookup implements CalculationParameter and is used by passing it as an argument to CalculationRules. It provides the link between the data that the function needs and the data that is available in ScenarioMarketData.

    Implementations of this interface must be immutable.

    • Method Detail

      • of

        static CreditRatesMarketDataLookup of​(java.util.Map<Pair<StandardId,​Currency>,​CurveId> creditCurveIds,
                                              java.util.Map<Currency,​CurveId> discountCurveIds,
                                              java.util.Map<StandardId,​CurveId> recoveryRateCurveIds)
        Obtains an instance based on a maps for credit, discount and recovery rate curves.
        Parameters:
        creditCurveIds - the credit curve identifiers, keyed by legal entity ID and currency
        discountCurveIds - the discount curve identifiers, keyed by currency
        recoveryRateCurveIds - the recovery rate curve identifiers, keyed by legal entity ID
        Returns:
        the rates lookup containing the specified curves
      • of

        static CreditRatesMarketDataLookup of​(java.util.Map<Pair<StandardId,​Currency>,​CurveId> creditCurveIds,
                                              java.util.Map<Currency,​CurveId> discountCurveIds,
                                              java.util.Map<StandardId,​CurveId> recoveryRateCurveIds,
                                              ObservableSource observableSource)
        Obtains an instance based on a maps for credit, discount and recovery rate curves.
        Parameters:
        creditCurveIds - the credit curve identifiers, keyed by legal entity ID and currency
        discountCurveIds - the discount curve identifiers, keyed by currency
        recoveryRateCurveIds - the recovery rate curve identifiers, keyed by legal entity ID
        observableSource - the source of market data for quotes and other observable market data
        Returns:
        the rates lookup containing the specified curves
      • requirements

        FunctionRequirements requirements​(StandardId legalEntityId,
                                          Currency currency)
        Creates market data requirements for the specified standard ID and currency.
        Parameters:
        legalEntityId - legal entity ID
        currency - the currency
        Returns:
        the requirements
        Throws:
        java.lang.IllegalArgumentException - if unable to create requirements
      • marketDataView

        default CreditRatesScenarioMarketData marketDataView​(ScenarioMarketData marketData)
        Obtains a filtered view of the complete set of market data.

        This method returns an instance that binds the lookup to the market data. The input is ScenarioMarketData, which contains market data for all scenarios.

        Parameters:
        marketData - the complete set of market data for all scenarios
        Returns:
        the filtered market data
      • marketDataView

        default CreditRatesMarketData marketDataView​(MarketData marketData)
        Obtains a filtered view of the complete set of market data.

        This method returns an instance that binds the lookup to the market data. The input is MarketData, which contains market data for one scenario.

        Parameters:
        marketData - the complete set of market data for one scenario
        Returns:
        the filtered market data
      • creditRatesProvider

        CreditRatesProvider creditRatesProvider​(MarketData marketData)
        Obtains credit rates provider based on the specified market data.

        This provides CreditRatesProvider suitable for pricing credit products. Although this method can be used directly, it is typically invoked indirectly via CreditRatesMarketData:

          // bind the baseData to this lookup
          CreditRatesMarketData view = lookup.marketView(baseData);
          
          // pass around CreditRatesMarketData within the function to use in pricing
          CreditRatesProvider provider = view.creditRatesProvider();
         
        Parameters:
        marketData - the complete set of market data for one scenario
        Returns:
        the rates provider