def _GetDateValues(<EOL>self, number_of_days, epoch_year, epoch_month, epoch_day_of_month):
if epoch_year < <NUM_LIT:0>:<EOL><INDENT>raise ValueError('<STR_LIT>'.format(<EOL>epoch_year))<EOL><DEDENT>if epoch_month not in range(<NUM_LIT:1>, <NUM_LIT>):<EOL><INDENT>raise ValueError('<STR_LIT>'.format(<EOL>epoch_month))<EOL><DEDENT>epoch_days_per_month = self._GetDaysPerMonth(epoch_year, epoch_month)<EOL>if epoch_day_of_month < <NUM_LIT:1> or epoch_day_of_month > epoch_days_per_month:<EOL><INDENT>raise ValueError('<STR_LIT>'.format(<EOL>epoch_day_of_month))<EOL><DEDENT>before_epoch = number_of_days < <NUM_LIT:0><EOL>year = epoch_year<EOL>month = epoch_month<EOL>if before_epoch:<EOL><INDENT>month -= <NUM_LIT:1><EOL>if month <= <NUM_LIT:0>:<EOL><INDENT>month = <NUM_LIT:12><EOL>year -= <NUM_LIT:1><EOL><DEDENT><DEDENT>number_of_days += epoch_day_of_month<EOL>if before_epoch:<EOL><INDENT>number_of_days *= -<NUM_LIT:1><EOL><DEDENT>while month > <NUM_LIT:1>:<EOL><INDENT>days_per_month = self._GetDaysPerMonth(year, month)<EOL>if number_of_days < days_per_month:<EOL><INDENT>break<EOL><DEDENT>if before_epoch:<EOL><INDENT>month -= <NUM_LIT:1><EOL><DEDENT>else:<EOL><INDENT>month += <NUM_LIT:1><EOL><DEDENT>if month > <NUM_LIT:12>:<EOL><INDENT>month = <NUM_LIT:1><EOL>year += <NUM_LIT:1><EOL><DEDENT>number_of_days -= days_per_month<EOL><DEDENT>_, remainder = divmod(year, <NUM_LIT:100>)<EOL>for _ in range(remainder, <NUM_LIT:100>):<EOL><INDENT>days_in_year = self._GetNumberOfDaysInYear(year)<EOL>if number_of_days < days_in_year:<EOL><INDENT>break<EOL><DEDENT>if before_epoch:<EOL><INDENT>year -= <NUM_LIT:1><EOL><DEDENT>else:<EOL><INDENT>year += <NUM_LIT:1><EOL><DEDENT>number_of_days -= days_in_year<EOL><DEDENT>days_in_century = self._GetNumberOfDaysInCentury(year)<EOL>while number_of_days > days_in_century:<EOL><INDENT>if before_epoch:<EOL><INDENT>year -= <NUM_LIT:100><EOL><DEDENT>else:<EOL><INDENT>year += <NUM_LIT:100><EOL><DEDENT>number_of_days -= days_in_century<EOL>days_in_century = self._GetNumberOfDaysInCentury(year)<EOL><DEDENT>days_in_year = self._GetNumberOfDaysInYear(year)<EOL>while number_of_days > days_in_year:<EOL><INDENT>if before_epoch:<EOL><INDENT>year -= <NUM_LIT:1><EOL><DEDENT>else:<EOL><INDENT>year += <NUM_LIT:1><EOL><DEDENT>number_of_days -= days_in_year<EOL>days_in_year = self._GetNumberOfDaysInYear(year)<EOL><DEDENT>days_per_month = self._GetDaysPerMonth(year, month)<EOL>while number_of_days > days_per_month:<EOL><INDENT>if before_epoch:<EOL><INDENT>month -= <NUM_LIT:1><EOL><DEDENT>else:<EOL><INDENT>month += <NUM_LIT:1><EOL><DEDENT>if month <= <NUM_LIT:0>:<EOL><INDENT>month = <NUM_LIT:12><EOL>year -= <NUM_LIT:1><EOL><DEDENT>elif month > <NUM_LIT:12>:<EOL><INDENT>month = <NUM_LIT:1><EOL>year += <NUM_LIT:1><EOL><DEDENT>number_of_days -= days_per_month<EOL>days_per_month = self._GetDaysPerMonth(year, month)<EOL><DEDENT>if before_epoch:<EOL><INDENT>days_per_month = self._GetDaysPerMonth(year, month)<EOL>number_of_days = days_per_month - number_of_days<EOL><DEDENT>elif number_of_days == <NUM_LIT:0>:<EOL><INDENT>number_of_days = <NUM_LIT><EOL>month = <NUM_LIT:12><EOL>year -= <NUM_LIT:1><EOL><DEDENT>return year, month, number_of_days<EOL>
Determines date values.

        Args:
          number_of_days (int): number of days since epoch.
          epoch_year (int): year that is the start of the epoch e.g. 1970.
          epoch_month (int): month that is the start of the epoch, where
              1 represents January.
          epoch_day_of_month (int): day of month that is the start of the epoch,
              where 1 represents the first day.

        Returns:
           tuple[int, int, int]: year, month, day of month.

        Raises:
          ValueError: if the epoch year, month or day of month values are out
              of bounds.