org.w3c.dom .views
import org.w3c.dom.Document;
import org.w3c.dom.views.AbstractView;
public class GetDocument {
public static void main(String[] args) {
// Get the View from an XML document
AbstractView view = ...;
// Get the underlying DOM document from the View
Document document = view.getDocument();
}
}import org.w3c.dom.Document;
import org.w3c.dom.views.AbstractView;
import org.w3c.dom.views.DocumentView;
public class CreateView {
public static void main(String[] args) {
// Get the View from an XML document
AbstractView view = ...;
// Create a new View from the existing View
DocumentView newView = DocumentView.createDocumentView(view.getDocument());
}
}