def formatTime(when, timeFormat=timeFormatRFC3339, default=u'-'):
 if ((timeFormat is None) or (when is None)):
  return default
 else:
  tz = FixedOffsetTimeZone.fromLocalTimeStamp(when)
  datetime = DateTime.fromtimestamp(when, tz)
  return unicode(datetime.strftime(timeFormat))

def formatTime ( when , timeFormat = timeFormatRFC3339 , default = u'-' ) : if ( ( timeFormat is None ) or ( when is None ) ) : return default else : tz = FixedOffsetTimeZone . fromLocalTimeStamp ( when ) datetime = DateTime . fromtimestamp ( when , tz ) return unicode ( datetime . strftime ( timeFormat ) )
format a timestamp as text .