|
From: Andrea <mar...@go...> - 2009-10-19 10:01:08
|
On 19/10/09 10:53, Andrea wrote:
> Hi,
>
> I've tried to use polymorphism in QuantLib-SWING Java version
>
> Something like
>
> class MyPayoff extends Payoff {}
I did try as well
class MyPayoff extends PlainVanillaPayoff
{
MyPayoff()
{
super(Option.Type.Put, 10.0);
}
public double getValue(double arg0)
{
throw new RuntimeException();
}
}
but the exception is never thrown.
I've used this class in the example EquityOptions.java.
|