aspose file tools*
The moose likes Java in General and the fly likes setting the xml child attributes value from parent's attribute value Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "setting the xml child attributes value from parent Watch "setting the xml child attributes value from parent New topic
Author

setting the xml child attributes value from parent's attribute value

bappa
Greenhorn

Joined: Mar 11, 2008
Posts: 15
Hi all,
I am working on xml parsing. My problem is to set the value of one attribute of child from the attribute value of parent. How to do this? Please help me in this concern. Thanks in advance.


S K B<br />SCJP 1.5 (83%)
Nickolas Case
Ranch Hand

Joined: Apr 26, 2008
Posts: 98
Just off the top of my head, try having a setter method in your child class set from the parent class. i.e:

public setThisAttribute(){
this.ThisAttribute = super.ThisAttribute;
}
I haven't tried to compile or anything. Good luck!
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: setting the xml child attributes value from parent's attribute value
 
Similar Threads
setting child attribute from parent attribute
Setting the attribute of child node by parent node attribute value
PASSED IBM 141-X ML - 76%
XPath for atrib. name and value of node
Deleting child nodes from an xml