aspose file tools*
The moose likes XML and Related Technologies and the fly likes Document Fragment Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Engineering » XML and Related Technologies
Bookmark "Document Fragment" Watch "Document Fragment" New topic
Author

Document Fragment

Palani kumar
Greenhorn

Joined: Sep 01, 2001
Posts: 12
Hai all
What is Document Fragment ? Can i create a document fragment without a root document object.
Can anyone help me how to use document fragment in java
Thanks
Palanikumar
------------------
In the end everything is Right,If it's not then It's not the End


In the end everything is Right,If it's not then It's not the End
Joe Gilvary
Ranch Hand

Joined: May 11, 2001
Posts: 152
A fragment is a "piece" of an XML file that includes
all of the markup for every construct it includes.
This could be a fragment:
<subtotal units="usd">
44.77
</subtotal>
<tax unit="usd">
2.77
</tax>

This could not be a fragment:
<subtotal units="usd">
44.77
</subtotal>
<tax unit="usd">
2.77
</tax>
</order>
The second example did not include all of the markup
for the order element, so it is not "well balanced"
and is not a good example of a fragment.
There's more documenatation at www.w3.org on
document fragments.
Joe
 
Consider Paul's rocket mass heater.
 
subject: Document Fragment