code: def to_header_str(self):
          
          h_parts = []
          if self.root:
              h_parts.append(ROOT + '=' + self.root)
          if self.parent:
              h_parts.append(PARENT + '=' + self.parent)
          if self.sampled is not None:
              h_parts.append(SAMPLE + '=' + str(self.sampled))
          if self.data:
              for key in self.data:
                  h_parts.append(key + '=' + self.data[key])
  
          return HEADER_DELIMITER.join(h_parts)
docs: Convert to a tracing header string that can be injected to
          outgoing http request headers.