Details
-
Type:
Improvement
-
Status:
Closed
-
Priority:
Minor
-
Resolution: Fixed
-
Affects Version/s: 1.5
-
Fix Version/s: 1.6-rc-1, 1.7-beta-1
-
Component/s: XML Processing
-
Labels:None
-
Patch Submitted:Yes
-
Number of attachments :
Description
For uses of XML parsing that go beyond the basic capabilities provided by XmlParser and Node, it would be good to be able to reuse the functionality provided by these classes, by subclassing them.
Currently this is not possible. This "improvement" is to alter these classes in a compatible way to allow subclassing, and to describe how to do this in the Documentation beneath the http://groovy.codehaus.org/Processing+XML page.
For example, one extension that I've done allows the parse result to record the file path, line number, and column number of the elements - these can be quite useful if you have some processing that can generate messages about the XML back to the user.
See the thread in the user mailing list for some more discussion on this: http://archive.codehaus.org/groovy/user/4765F82F.9030601@schor.com
Attachments
Issue Links
| This issue relates to: | ||||
| GROOVY-2429 | Allow subclasses of XmlParser to customize creation of new Nodes |
|
|
|
| GROOVY-2415 | Add 1 argument constructor to groovy.util.Node, and corresponding groovy.util.XmlParser appendNode('someElementName') method |
|
|
|
A suggest approach to resolving this issue