WTP Structured Document
In the previous article we have built our own jspeditor based on WTP's Structuredtexteditor, which will introduce one of the most important data models for our editor: Istructureddocument (Org.eclipse.wst.sse.core.internal.provisional.text.IStructuredDocument), the next article will introduce another istructuredmodel. Look at the Istructureddocument type system as follows:
Above, we see the figure of Istructureddocument, which is the IDocument interface implementation in the JFace Text framework, The chosen jobsafestructureeddocument is the istructureddocument realization that we have to face.
PS: From the type name can be guessed out, basicstructureddocument should be a similar to the default adapter role, specifically? Go and see ^_^ yourself.
"Istructureddocument structure--composite"
So as long as we look at JSP and we know that other documents that are essentially a tree-like structure, how do we build this document? It is natural that the underlying XML is used to describe the JSP, and then the XML model is built, and our document implementation is established (note: The WTP XML model mentioned in the next article, "Istructuredmodel"). Since it is tree-like, the interface is generally written in composite mode. Let's take a look at a istructureddocument interface diagram: