def processElementNodeByFunction(elementNode, manipulationFunction):
 if ('target' not in elementNode.attributes):
  print 'Warning, there was no target in processElementNodeByFunction in solid for:'
  print elementNode
  return
 target = evaluate.getEvaluatedLinkValue(elementNode, str(elementNode.attributes['target']).strip())
 if (target.__class__.__name__ == 'ElementNode'):
  manipulationFunction(elementNode, target)
  return
 path.convertElementNode(elementNode, target)
 manipulationFunction(elementNode, elementNode)

def processElementNodeByFunction ( elementNode , manipulationFunction ) : if ( 'target' not in elementNode . attributes ) : print 'Warning, there was no target in processElementNodeByFunction in solid for:' print elementNode return target = evaluate . getEvaluatedLinkValue ( elementNode , str ( elementNode . attributes [ 'target' ] ) . strip ( ) ) if ( target . __class__ . __name__ == 'ElementNode' ) : manipulationFunction ( elementNode , target ) return path . convertElementNode ( elementNode , target ) manipulationFunction ( elementNode , elementNode )
process the xml element by the manipulationfunction .