//JAVA TO C# CONVERTER WARNING: Java wildcard generics have no direct equivalent in .NET: //ORIGINAL LINE: @Override public com.google.common.collect.ImmutableSet<com.opengamma.strata.data.MarketDataId<?>> getVolatilityIds(com.opengamma.strata.basics.index.IborIndex index) public ImmutableSet <MarketDataId <object> > getVolatilityIds(IborIndex index) { SwaptionVolatilitiesId id = volatilityIds.get(index); if (id == null) { throw new System.ArgumentException(msgIndexNotFound(index)); } return(ImmutableSet.of(id)); }
//------------------------------------------------------------------------- public SwaptionVolatilities volatilities(IborIndex index, MarketData marketData) { SwaptionVolatilitiesId volatilityId = volatilityIds.get(index); if (volatilityId == null) { throw new MarketDataNotFoundException(msgIndexNotFound(index)); } return(marketData.getValue(volatilityId)); }
//------------------------------------------------------------------------- /// <summary> /// Obtains an instance based on a single mapping from index to volatility identifier. /// <para> /// The lookup provides volatilities for the specified index. /// /// </para> /// </summary> /// <param name="index"> the Ibor index </param> /// <param name="volatilityId"> the volatility identifier </param> /// <returns> the swaption lookup containing the specified mapping </returns> public static DefaultSwaptionMarketDataLookup of(IborIndex index, SwaptionVolatilitiesId volatilityId) { return(new DefaultSwaptionMarketDataLookup(ImmutableMap.of(index, volatilityId))); }