#NEWLINE# def append( self , parent , content ) : #NEWLINE# #INDENT# d = content . value #NEWLINE# if ( self . optional ( content ) and ( len ( d ) == 0 ) ) : #NEWLINE# #INDENT# return #NEWLINE# #UNINDENT# child = self . node ( content ) #NEWLINE# parent . append ( child ) #NEWLINE# for item in d . items ( ) : #NEWLINE# #INDENT# cont = Content ( tag = item [ 0 ] , value = item [ 1 ] ) #NEWLINE# Appender . append ( self , child , cont )