code: public static DiscountCurveInterpolation createDiscountCurveFromDiscountFactors(
  			String name, LocalDate referenceDate,
  			double[] times, double[] givenDiscountFactors, boolean[] isParameter,
  			InterpolationMethod interpolationMethod, ExtrapolationMethod extrapolationMethod, InterpolationEntity interpolationEntity) {
  
  		DiscountCurveInterpolation discountFactors = new DiscountCurveInterpolation(name, referenceDate, interpolationMethod, extrapolationMethod, interpolationEntity);
  
  		for(int timeIndex=0; timeIndex<times.length;timeIndex++) {
  			discountFactors.addDiscountFactor(times[timeIndex], givenDiscountFactors[timeIndex], isParameter != null && isParameter[timeIndex]);
  		}
  
  		return discountFactors;
  	}
docs: Create a discount curve from given times and given discount factors using given interpolation and extrapolation methods.
  
  @param name The name of this discount curve.
  @param referenceDate The reference date for this curve, i.e., the date which defined t=0.
  @param times Array of times as doubles.
  @param givenDiscountFactors Array of corresponding discount factors.
  @param isParameter Array of booleans specifying whether this point is served "as as parameter", e.g., whether it is calibrates (e.g. using CalibratedCurves).
  @param interpolationMethod The interpolation method used for the curve.
  @param extrapolationMethod The extrapolation method used for the curve.
  @param interpolationEntity The entity interpolated/extrapolated.
  @return A new discount factor object.