'Return ISO 8601 string for the given datetime'

def _format_datetime(self, date_time):

    if (date_time is None):
        return None
    timezone_hrs = ((time.timezone / 60) / 60)
    if (timezone_hrs >= 0):
        timezone_join = '+'
    else:
        timezone_join = ''
    timezone_spec = ('%s%s:00' % (timezone_join, timezone_hrs))
    return (date_time.strftime('%Y-%m-%dT%H:%M:%S') + timezone_spec)
