Example #1
0
 private CashSwaptionSettlement(LocalDate settlementDate, CashSwaptionSettlementMethod method)
 {
     JodaBeanUtils.notNull(settlementDate, "settlementDate");
     JodaBeanUtils.notNull(method, "method");
     this.settlementDate = settlementDate;
     this.method         = method;
 }
Example #2
0
            public override Builder set(string propertyName, object newValue)
            {
                switch (propertyName.GetHashCode())
                {
                case -295948169:         // settlementDate
                    this.settlementDate = (LocalDate)newValue;
                    break;

                case -1077554975:         // method
                    this.method = (CashSwaptionSettlementMethod)newValue;
                    break;

                default:
                    throw new NoSuchElementException("Unknown property: " + propertyName);
                }
                return(this);
            }
Example #3
0
 //-------------------------------------------------------------------------
 /// <summary>
 /// Obtains an instance from the settlement date and method.
 /// </summary>
 /// <param name="settlementDate">  the settlement date </param>
 /// <param name="method">  the settlement method </param>
 /// <returns> the settlement </returns>
 public static CashSwaptionSettlement of(LocalDate settlementDate, CashSwaptionSettlementMethod method)
 {
     return(new CashSwaptionSettlement(settlementDate, method));
 }