private static boolean dateByOrdinal(DateTimeFormatterBuilder bld,Collection<DateTimeFieldType> fields,boolean extended,boolean strictISO){
  boolean reducedPrec=false;
  if (fields.remove(DateTimeFieldType.year())) {
    bld.append(yearElement());
    if (fields.remove(DateTimeFieldType.dayOfYear())) {
      appendSeparator(bld,extended);
      bld.appendDayOfYear(3);
    }
 else {
      reducedPrec=true;
    }
  }
 else   if (fields.remove(DateTimeFieldType.dayOfYear())) {
    bld.appendLiteral('-');
    bld.appendDayOfYear(3);
  }
  return reducedPrec;
}

private static boolean dateByOrdinal ( DateTimeFormatterBuilder bld , Collection < DateTimeFieldType > fields , boolean extended , boolean strictISO ) { boolean reducedPrec = false ; if ( fields . remove ( DateTimeFieldType . year ( ) ) ) { bld . append ( yearElement ( ) ) ; if ( fields . remove ( DateTimeFieldType . dayOfYear ( ) ) ) { appendSeparator ( bld , extended ) ; bld . appendDayOfYear ( 3 ) ; } else { reducedPrec = true ; } } else if ( fields . remove ( DateTimeFieldType . dayOfYear ( ) ) ) { bld . appendLiteral ( '-' ) ; bld . appendDayOfYear ( 3 ) ; } return reducedPrec ; }
creates a date using the ordinal date format . specification reference : 5 . 2 . 2 .
