code: def toxml(self):
          
  
          return '<With ' + \
            (' instance="{0}"'.format(self.instance) if self.instance else '') +\
            (' list="{0}"'.format(self.list) if self.list else '') + \
            (' index="{0}"'.format(self.index) if self.index else '') + \
            ' as="{1}"/>'.format(self.instance, self.as_)
docs: Exports this object into a LEMS XML object