WSDLEditor.CustomExtensibilityElements

WSDL Editor provides support for creation of wsdl extensibility elements in various UI elements in the wsdl design view.

WSDL extensibility elements:
In the wsdl schema, there are specific elements which extend from wsdl:tExtensibleDocumented (which can take xsd:any) (refer wsdl.xsd ) like:

  • definitions
  • types
  • binding
  • binding operation
  • binding input
  • binding output
  • binding fault
  • service port and so on.

These are points where extensibility elements can be inserted.


What does wsdl editor need from extensiblity element provider?

  1. Schema file representing the elements that could go under any extensibility elements.
  2. Specify which element goes under which wsdl extension points.

This is done through the layer extension mechanism. Sample layer.xml is as follows:

<folder name="WSDLEditor">
        <file name="file-ext.xsd" url="file-ext.xsd">
            <attr name="namespace" stringvalue="http://schemas.sun.com/jbi/wsdl-extensions/file/" />
            <attr name="prefix" stringvalue="file" />
        </file>
        
        <folder name ="Binding">
            <file name="FileBinding">
                <attr name="xsdFileName" stringvalue="file-ext" />
                <attr name="element" stringvalue="binding" />
                <attr name="SystemFileSystem.localizingBundle" stringvalue="org.netbeans.modules.wsdlextensions.file.resources.Bundle" />
                <attr name="SystemFileSystem.icon" urlvalue="nbresloc:/org/netbeans/modules/wsdlextensions/file/resources/throw16.png" /> 
            </file>
        </folder>
     
        <folder name ="BindingOperation">
            <file name="FileBindingOperation">
                <attr name="xsdFileName" stringvalue="file-ext" />
                <attr name="element" stringvalue="operation" />
                <attr name="SystemFileSystem.localizingBundle" stringvalue="org.netbeans.modules.wsdlextensions.file.resources.Bundle" />
                <attr name="SystemFileSystem.icon" urlvalue="nbresloc:/org/netbeans/modules/wsdlextensions/file/resources/onalarm16x16.png" /> 
            </file>
        </folder>
			
        <folder name ="BindingOperationInput">
            <file name="FileBindingMessage">
                <attr name="xsdFileName" stringvalue="file-ext" />
                <attr name="element" stringvalue="message" />
                <attr name="SystemFileSystem.localizingBundle" stringvalue="org.netbeans.modules.wsdlextensions.file.resources.Bundle" />
                <attr name="SystemFileSystem.icon" urlvalue="nbresloc:/org/netbeans/modules/wsdlextensions/file/resources/onmessage16x16.png" /> 
            </file>
        </folder>	        
	      
        <folder name ="BindingOperationOutput">
            <file name="FileBindingMessage">
                <attr name="xsdFileName" stringvalue="file-ext" />
                <attr name="element" stringvalue="message" />
                <attr name="SystemFileSystem.localizingBundle" stringvalue="org.netbeans.modules.wsdlextensions.file.resources.Bundle" />
                <attr name="SystemFileSystem.icon" urlvalue="nbresloc:/org/netbeans/modules/wsdlextensions/file/resources/scope16x16.png" /> 
            </file>
	</folder>	        
  
        <folder name ="ServicePort">
            <file name="FileServicePort" >
                <attr name="xsdFileName" stringvalue="file-ext" />
                <attr name="element" stringvalue="address" />
                <attr name="SystemFileSystem.localizingBundle" stringvalue="org.netbeans.modules.wsdlextensions.file.resources.Bundle" />
                <attr name="SystemFileSystem.icon" urlvalue="nbresloc:/org/netbeans/modules/wsdlextensions/file/resources/while16x16.png" /> 
            </file>
        </folder>	        
    </folder>

The steps to do this are:

  1. Create a netbeans module.
  2. In the layer.xml, create a folder called WSDLEditor
  3. Create a file which points to the schema that your extensibility element would adhere to.
  4. Create specific folders, provide the element name, bundle properties, and icon.
  • Possible folder names which can take extensibility elements are as follows:
Definitions
PortTypeOperation
Message
Binding
BindingOperation
BindingOperationInput
BindingOperationOutput
BindingOperationFault
Service
ServicePort
        

Look for examples in :

  1. For binding extensiions, see layer files in modules in main repository wsdlextension.file, wsdlextension.jms, xml.wsdlextui
  2. For definition extensions, see layer files in xml.wsdlui.
Not logged in. Log in, Register

By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2012, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo