code: def toxml(self):
          
  
          return '<ComponentRequirement name="{0}"'.format(self.name) + '' + \
              (' description = "{0}"'.format(self.description) if self.description else '') +\
              '/>'
docs: Exports this object into a LEMS XML object