Jump to content
groovyPost Forums

[Help Needed] Parsing in Groovy

Recommended Posts

I am new in groovy and I hope to solicit your feedback.

I have a requirement to parse the content from the xml and generate new xml dynamically.


1. Parse Param using & as identifier    
2. Put parsed data to an array. e.g. array: [fanme=Hello, lname=World]
3. Loop into the array while creating an xml. Value element below, should be dynamically generated based on the array content.
    e.g <Info>
            <Value name=fname>Hello</Value>
            <Value name=lname>World</Value>

5. Return the result/generated xml document as a string.

I hope you can help me on this case study.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Who's Online   0 Members, 0 Anonymous, 7 Guests (See full list)

    • There are no registered users currently online
  • Create New...