parameters: (self, dt)
docstring: Converts datetime to Timestamp.
docstring_summary: Converts datetime to Timestamp.
docstring_tokens: Converts datetime to Timestamp .
function: def FromDatetime(self, dt):
      """Converts datetime to Timestamp."""
      td = dt - datetime(1970, 1, 1)
      self.seconds = td.seconds + td.days * _SECONDS_PER_DAY
      self.nanos = td.microseconds * _NANOS_PER_MICROSECOND
function_tokens: def FromDatetime ( self , dt ) : td = dt - datetime ( 1970 , 1 , 1 ) self . seconds = td . seconds + td . days * _SECONDS_PER_DAY self . nanos = td . microseconds * _NANOS_PER_MICROSECOND