Examples of ForexOptionSingleBarrierDefinition


Examples of com.opengamma.analytics.financial.forex.definition.ForexOptionSingleBarrierDefinition

    final Barrier barrier = new Barrier(getKnockType(barrierOptionSecurity.getBarrierDirection()), getBarrierType(barrierOptionSecurity.getBarrierType()),
        getObservationType(barrierOptionSecurity.getMonitoringType()), level);
    final ZonedDateTime settlementDate = barrierOptionSecurity.getSettlementDate();
    final ForexDefinition underlying = new ForexDefinition(putCurrency, callCurrency, settlementDate, putAmount, fxRate); //TODO this needs its own converter
    final boolean isLong = barrierOptionSecurity.isLong();
    return new ForexOptionSingleBarrierDefinition(new ForexOptionVanillaDefinition(underlying, expiry, true, isLong), barrier);
  }
View Full Code Here

Examples of com.opengamma.analytics.financial.forex.definition.ForexOptionSingleBarrierDefinition

      isCall = false;
    } else {
      underlying = ForexDefinition.fromAmounts(callCurrency, putCurrency, settlementDate, callAmount, -putAmount);
      isCall = true;
    }
    return new ForexOptionSingleBarrierDefinition(new ForexOptionVanillaDefinition(underlying, expiry, isCall, isLong), barrier);
  }
View Full Code Here

Examples of com.opengamma.analytics.financial.forex.definition.ForexOptionSingleBarrierDefinition

  /**
   * Creates a single-barrier FX option definition
   * @return A single-barrier FX option definition
   */
  public static ForexOptionSingleBarrierDefinition createForexOptionSingleBarrierDefinition() {
    return new ForexOptionSingleBarrierDefinition(FX_OPTION_DEFINITION, BARRIER);
  }
View Full Code Here

Examples of com.opengamma.analytics.financial.forex.definition.ForexOptionSingleBarrierDefinition

    final ZonedDateTime settlementDate = barrierOptionSecurity.getSettlementDate();
    final ForexDefinition underlying = new ForexDefinition(putCurrency, callCurrency, settlementDate, putAmount, fxRate); //TODO this needs its own converter
    final boolean isLong = barrierOptionSecurity.isLong();
    final Barrier barrier = new Barrier(getKnockType(barrierOptionSecurity.getBarrierDirection()), getBarrierType(barrierOptionSecurity.getBarrierType()),
        getObservationType(barrierOptionSecurity.getMonitoringType()), level);
    return new ForexOptionSingleBarrierDefinition(new ForexOptionVanillaDefinition(underlying, expiry, true, isLong), barrier);
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.