def _CalculateTimeDiff(date1, date2):
  """Calculate a time difference string based on two provided datetimes.

  Args:
    date1: A datetime.datetime object.
    date2: A datetime.datetime object.

  Returns:
    A string indicating the time difference between the two datetimes.
  """
  timediff = abs(date1-date2)
  diff_seconds = timediff.seconds
  days, remainder = divmod(diff_seconds, 24*3600)
  hours, remainder = divmod(remainder, 3600)
  minutes, seconds = divmod(remainder, 60)
  if days > 0:
    return '%02d Days, %02dh:%02dm:%02ds' % (days, hours, minutes, seconds)
  else:
    return '%02dh:%02dm:%02ds' % (hours, minutes, seconds)