Understanding the XSLT Designer

ProcedureTo create the XML Schema for the outgoing message:

  1. In the Projects window, right-click the HelloXSLTransformation > Transformation Files node and choose New > XML Schema.

  2. In the File Name field, type HelloXSLTOutgoing.

  3. Click Finish. A new node—HelloXSLTOutgoing.xsd —appears under the Transformation Files node in your HelloXSLTransformation project and the new Schema opens in the XML Schema Editor.

  4. In the first column of the Schema view, right-click Elements and choose Add Element from the pop-up menu. The Element dialog box opens.

  5. In the Name field, type greeting.

  6. Under Type, select the Use Existing Type radio button.

  7. Expand the Built-in Types node and select string.

  8. Click OK.

  9. To view the source of the Schema you created, click the Source button on the XML Schema Editor toolbar. You should see the following code:


    <?xml version="1.0" encoding="UTF-8"?>
    <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
                targetNamespace="http://xml.netbeans.org/schema/HelloXSLTOutgoing"
                xmlns:tns="http://xml.netbeans.org/schema/HelloXSLTOutgoing"
                elementFormDefault="qualified">
        <xsd:element name="greeting" type="xsd:string"></xsd:element>
    </xsd:schema>
  10. Click the Save All button on the toolbar.

    You should see two Schema files listed under the Transformation Files node in your HelloXSLTransformation project.

    Two Schema Files in the Project