/src/main/java/net/finmath/modelling/productfactory/InterestRateMonteCarloProductFactory.java
legDescriptor     = descriptor.getLegPayer( ) ; legReceiver     = ( TermStructureMonteCarloProduct) factory.getProductFromDescriptor( legDescriptor) ;
legReceiver     = ( TermStructureMonteCarloProduct ) factory.getProductFromDescriptor ( legDescriptor ) ; legDescriptor     = descriptor.getLegPayer ( ) ;
public static class SwapMonteCarlo extends AbstractTermStructureMonteCarloProduct implements DescribedProduct<InterestRateSwapProductDescriptor> { private final TermStructureMonteCarloProduct legReceiver; private final TermStructureMonteCarloProduct legPayer; public SwapMonteCarlo(final InterestRateSwapProductDescriptor descriptor, final LocalDate referenceDate) { final InterestRateMonteCarloProductFactory factory = new InterestRateMonteCarloProductFactory(referenceDate); InterestRateProductDescriptor legDescriptor = descriptor.getLegReceiver(); <extra_id_0> legPayer = (TermStructureMonteCarloProduct) factory.getProductFromDescriptor(legDescriptor); } @Override public RandomVariable getValue(final double evaluationTime, final TermStructureMonteCarloSimulationModel model) throws CalculationException { RandomVariable value = new RandomVariableFromDoubleArray(0); if(legPayer != null) {