code: def _mets_header(self, now):
          
          header_tag = etree.QName(utils.NAMESPACES[u"mets"], u"metsHdr")
          header_attrs = {}
  
          if self.createdate is None:
              header_attrs[u"CREATEDATE"] = now
          else:
              header_attrs[u"CREATEDATE"] = self.createdate
              header_attrs[u"LASTMODDATE"] = now
  
          header_element = etree.Element(header_tag, **header_attrs)
          for agent in self.agents:
              header_element.append(agent.serialize())
          for alternate_id in self.alternate_ids:
              header_element.append(alternate_id.serialize())
  
          return header_element
docs: Return the metsHdr Element.