Forum Discussion

praneeth12's avatar
Occasional Contributor
4 years ago

Add/remove elements from xml-request

How to  remove single element from xml.Below is the code for specific element but i am not able to delete selected element from the xml and serialize xml.


def slurped = new XmlSlurper().parseText(requestXML1)

//grope of eliment size 4
def gropeOfEliments= slurped.'**'.findAll{ == 'licenseStatus' 


//how to delete 3rd element and serialize with 3 eliments.


1 Reply