public MonetaryOperatorAdapter(Rate rate) {
Objects.requireNonNull(rate);
this.rate = rate;
}
@Override
<BUG>public <T extends MonetaryAmount> T apply(T amount) {
return (T) PresentValuePerpetuity.of().calculate(amount,
rate);</BUG>
}
@Override

public MonetaryOperatorAdapter(Rate rate) {
Objects.requireNonNull(rate);
this.rate = rate;
}
@Override
public MonetaryAmount apply(MonetaryAmount amount) {
return PresentValuePerpetuity.of().calculate(amount,
rate);
}
@Override
