code: private TimephasedCost splitCostStart(ProjectCalendar calendar, double totalAmount, Date start)
     {
        TimephasedCost cost = new TimephasedCost();
        cost.setStart(start);
        cost.setFinish(calendar.getDate(start, Duration.getInstance(1, TimeUnit.DAYS), false));
        cost.setAmountPerDay(Double.valueOf(totalAmount));
        cost.setTotalAmount(Double.valueOf(totalAmount));
  
        return cost;
     }
docs: Used for Cost type Resources.
  
  Generates a TimphasedCost block for the total amount on the start date. This is useful
  for Cost resources that have an AccrueAt value of Start.
  
  @param calendar calendar used by this assignment
  @param totalAmount cost amount for this block
  @param start start date of the timephased cost block
  @return timephased cost