@Override
public boolean canApplyTo(final FunctionCompilationContext context, final ComputationTarget target) {
final Security security = target.getSecurity();
final FXOptionSecurity fxOption = (FXOptionSecurity) security;
final Currency putCurrency = fxOption.accept(ForexVisitors.getPutCurrencyVisitor());
final Currency callCurrency = fxOption.accept(ForexVisitors.getCallCurrencyVisitor());
final String currencyPair = UnorderedCurrencyPair.of(putCurrency, callCurrency).getObjectId().getValue();
if (getAllCurrencyPairs().contains(currencyPair)) {
return true;
}
final String firstCcy = currencyPair.substring(0, 3);