GapOptionFunctionProvider extends OptionFunctionProvider1D { public double getStrikePayoff() { return _payoffStrike; } GapOptionFunctionProvider(final double strike, final double timeToExpiry, final int steps, final boolean isCall, final double payoffStrike); @Override double[] getPayoffAtExpiry(final double assetPrice, final double downFactor, final double upOverDown); @Override double[] getPayoffAtExpiryTrinomial(final double assetPrice, final double downFactor, final double middleOverDown); double getStrikePayoff(); @Override int hashCode(); @Override boolean equals(Object obj);  }
@Test public void getStrikePayoffTest() { final GapOptionFunctionProvider function = new GapOptionFunctionProvider(103., 1., 1003, true, 105.5); assertEquals(function.getStrikePayoff(), 105.5); }