public override int GetHashCode() { int hash = this.GetType().GetHashCode(); hash = hash * 31 + JodaBeanUtils.GetHashCode(parameters); hash = hash * 31 + JodaBeanUtils.GetHashCode(dayCount); hash = hash * 31 + JodaBeanUtils.GetHashCode(valuationDateTime); return hash; }
private HullWhiteOneFactorPiecewiseConstantParametersProvider(HullWhiteOneFactorPiecewiseConstantParameters parameters, DayCount dayCount, ZonedDateTime valuationDateTime) { JodaBeanUtils.notNull(parameters, "parameters"); JodaBeanUtils.notNull(dayCount, "dayCount"); JodaBeanUtils.notNull(valuationDateTime, "valuationDateTime"); this.parameters = parameters; this.dayCount = dayCount; this.valuationDateTime = valuationDateTime; }
//----------------------------------------------------------------------- public override string ToString() { StringBuilder buf = new StringBuilder(128); buf.Append("HullWhiteOneFactorPiecewiseConstantParametersProvider.Builder{"); buf.Append("parameters").Append('=').Append(JodaBeanUtils.ToString(parameters)).Append(',').Append(' '); buf.Append("dayCount").Append('=').Append(JodaBeanUtils.ToString(dayCount)).Append(',').Append(' '); buf.Append("valuationDateTime").Append('=').Append(JodaBeanUtils.ToString(valuationDateTime)); buf.Append('}'); return buf.ToString(); }
//----------------------------------------------------------------------- public override bool Equals(object obj) { if (obj == this) { return true; } if (obj != null && obj.GetType() == this.GetType()) { HullWhiteOneFactorPiecewiseConstantParametersProvider other = (HullWhiteOneFactorPiecewiseConstantParametersProvider) obj; return JodaBeanUtils.equal(parameters, other.parameters) && JodaBeanUtils.equal(dayCount, other.dayCount) && JodaBeanUtils.equal(valuationDateTime, other.valuationDateTime); } return false; }