#NEWLINE# def as_xml( self ) : #NEWLINE# #INDENT# element = ElementTree . Element ( FEATURE_BIND ) #NEWLINE# if self . jid : #NEWLINE# #INDENT# sub = ElementTree . SubElement ( element , BIND_JID_TAG ) #NEWLINE# sub . text = str ( self . jid ) #NEWLINE# #UNINDENT# if self . resource : #NEWLINE# #INDENT# sub = ElementTree . SubElement ( element , BIND_RESOURCE_TAG ) #NEWLINE# sub . text = self . resource #NEWLINE# #UNINDENT# return element