Moving to XML
|
Add a root ('content') element
doc.appendChild( new ElementImpl( doc, "eventsdiary"));
Element content = doc.getDocumentElement();
-
Every Document must have exactly one 'content' element
-
If you attempt to add another child to a document which
already has a child, that's an error.
An older version of this course
is available here