code: public static YearMonthDay fromDateFields(Date date) {
          if (date == null) {
              throw new IllegalArgumentException("The date must not be null");
          }
          return new YearMonthDay(
              date.getYear() + 1900,
              date.getMonth() + 1,
              date.getDate()
          );
      }
docs: Constructs a YearMonthDay from a <code>java.util.Date</code>
  using exactly the same field values avoiding any time zone effects.
  <p>
  Each field is queried from the Date and assigned to the YearMonthDay.
  This is useful if you have been using the Date as a local date,
  ignoring the zone.
  <p>
  This factory method always creates a YearMonthDay with ISO chronology.
  
  @param date  the Date to extract fields from
  @return the created YearMonthDay
  @throws IllegalArgumentException if the calendar is null
  @throws IllegalArgumentException if the date is invalid for the ISO chronology
  @since 1.2