Package org.apache.woden

Examples of org.apache.woden.WSDLFactory


    /*
     * Test that the associated InterfaceMessageReferenceElement can be retrieved.
     */
    public void testGetInterfaceMessageReferenceElement()
    {
        WSDLFactory factory = null;
        try {
            factory = WSDLFactory.newInstance();
        } catch (WSDLException e) {
            fail("Can't instantiate the WSDLFactory object.");
        }

        DescriptionElement descriptionElement = factory.newDescription();
       
        // Create the BindingElement->InterfaceElement->InterfaceOperationElement->InterfaceMessageReferenceElement
        BindingElement bindingElement = descriptionElement.addBindingElement();
        bindingElement.setInterfaceName(new QName("interface1"));
       
View Full Code Here


     */
    protected void setUp() throws Exception
    {
        super.setUp();
       
        WSDLFactory factory = null;
        try {
            factory = WSDLFactory.newInstance();
        } catch (WSDLException e) {
            fail("Can't instantiate the WSDLFactory object.");
        }
       
        fDescriptionElement = factory.newDescription();
        fInterfaceElement = fDescriptionElement.addInterfaceElement();
        fInterfaceOperationElement = fInterfaceElement.addInterfaceOperationElement();
        fStyleURI1 = new URI("http://www.w3.org/0000/00/apacheStyle");
        fStyleURI2 = new URI("http://www.w3.org/0000/00/anotherApacheStyle");
        fPattern = new URI("http://www.w3.org/0000/00/wsdl/in-out");
View Full Code Here

        return new TestSuite(ExtensionRegistryTest.class);
    }
   
    protected void setUp() throws Exception {
        super.setUp();
        WSDLFactory factory = WSDLFactory.newInstance();
        WSDLReader reader = factory.newWSDLReader();
        fExtReg = reader.getExtensionRegistry();
    }
View Full Code Here

   * - getInterfaceMessageReference()
   *
   */
  public void testGetInterfaceMessageReference()
  {
        WSDLFactory factory = null;
        try {
            factory = WSDLFactory.newInstance();
        } catch (WSDLException e) {
            fail("Can't instantiate the WSDLFactory object.");
        }

        DescriptionElement descriptionElement = factory.newDescription();

    // Create the BindingElement<->InterfaceElement->InterfaceOperationElement->InterfaceMessageReferenceElement hierarchy
    BindingElement bindingElement = descriptionElement.addBindingElement();
    bindingElement.setInterfaceName(new QName("interface1"));
   
View Full Code Here

  /*
   * Test that the (Mandatory) InterfaceFault can be successfully retrieved.
   */
  public void testGetInterfaceFaultElement()
  {
        WSDLFactory factory = null;
        try {
            factory = WSDLFactory.newInstance();
        } catch (WSDLException e) {
            fail("Can't instantiate the WSDLFactory object.");
        }

    DescriptionElement descriptionElement = factory.newDescription();

    // Create the BindingElement<->InterfaceElement->InterfaceFaultElement hierarchy
    BindingElement bindingElement = descriptionElement.addBindingElement();
    bindingElement.setInterfaceName(new QName("interface1"));
   
View Full Code Here

     * @see TestCase#setUp()
     */
    protected void setUp() throws Exception
    {
        super.setUp();
        WSDLFactory factory = WSDLFactory.newInstance();
      fDescriptionElement = factory.newDescription();
      fBindingElement = fDescriptionElement.addBindingElement();
      fBindingElement.setName(new NCName("bindingName"));
      fInterfaceElement = fDescriptionElement.addInterfaceElement();
      fInterfaceElement.setName(new NCName("interfaceName"));
      fServiceElement = fDescriptionElement.addServiceElement();
View Full Code Here

     */
    protected void setUp() throws Exception
    {
        super.setUp();

        WSDLFactory factory = null;
        try {
            factory = WSDLFactory.newInstance();
        } catch (WSDLException e) {
            fail("Can't instantiate the WSDLFactory object.");
        }
       
        fDescriptionElement = factory.newDescription();
        fInterfaceElement = fDescriptionElement.addInterfaceElement();
        fStyleDefaultURI1 = new URI("http://www.w3.org/0000/00/apacheStyle");
        fStyleDefaultURI2 = new URI("http://www.w3.org/0000/00/anotherApacheStyle");
    }
View Full Code Here

     * @see TestCase#setUp()
     */
    protected void setUp() throws Exception
    {
        super.setUp();
        WSDLFactory factory = null;
        try {
            factory = WSDLFactory.newInstance();
        } catch (WSDLException e) {
            fail("Can't instantiate the WSDLFactory object.");
        }
        fDescriptionElement = factory.newDescription();
        fDescriptionElement.setTargetNamespace(URI.create(TNS));
        fInterfaceElement = fDescriptionElement.addInterfaceElement();
        fInterfaceElement.setName(new NCName(INTF_NAME));
        fInterfaceOperationElement = fInterfaceElement.addInterfaceOperationElement();
        fInterfaceOperationElement.setName(new NCName(OPER_NAME));
View Full Code Here

   * Test that the (Mandatory) InterfaceFaultReference can be successfully retrieved.
   * The fault reference is to an Interface Fault associated with the grandparent BindingElement.
   */
  public void testGetInterfaceFaultReferenceElement()
  {
        WSDLFactory factory = null;
        try {
            factory = WSDLFactory.newInstance();
        } catch (WSDLException e) {
            fail("Can't instantiate the WSDLFactory object.");
        }

    DescriptionElement descriptionElement = factory.newDescription();
   
    // Create the BindingElement<->InterfaceElement->InterfaceOperationElement->InterfaceFaultReferenceElement hierarchy
    BindingElement bindingElement = descriptionElement.addBindingElement();
    bindingElement.setInterfaceName(new QName("interface1"));
   
View Full Code Here

  {   
    // check the default:
    Interface retrievedInterface = fBinding.getInterface();
    assertNull("Retrieved Interface should be null if none set -", retrievedInterface);

        WSDLFactory factory = null;
        try {
            factory = WSDLFactory.newInstance();
        } catch (WSDLException e) {
            fail("Can't instantiate the WSDLFactory object.");
        }

    // Create and name an Interface Element
    DescriptionElement desc = factory.newDescription();
    InterfaceElement interfaceElement = desc.addInterfaceElement();
    interfaceElement.setName(new NCName("interface1"));
   
    // Create a binding from the description 
    fBindingElement = desc.addBindingElement();
    fBindingElement.setName(new NCName("binding1"));
    desc.toComponent();
    Binding binding = desc.toComponent().getBinding(new QName("binding1"));
 
    // getInterface() - interface attribute unspecified, but hierarchy in place:
    retrievedInterface = binding.getInterface();
    assertNull("Retrieved Interface should be null if interface attribute unspecified -", retrievedInterface);
   
    // getInterface() - interface attribute specified, and hierarchy in place:
    // Set the "interface" attribute to reference the new Interface Element
    // (have to recreate whole desc hierarchy as toComponent() will not rerun if already run!)
    desc = factory.newDescription();
    interfaceElement = desc.addInterfaceElement();
    interfaceElement.setName(new NCName("interface1"));
    fBindingElement = desc.addBindingElement();
    fBindingElement.setName(new NCName("binding1"));
    fBindingElement.setInterfaceName(new QName("interface1"));
View Full Code Here

TOP

Related Classes of org.apache.woden.WSDLFactory

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.