Class DefaultConcretePartProvider

java.lang.Object
org.springframework.ws.wsdl.wsdl11.provider.DefaultConcretePartProvider
All Implemented Interfaces:
BindingsProvider, ServicesProvider
Direct Known Subclasses:
Soap11Provider, Soap12Provider

public class DefaultConcretePartProvider extends Object implements BindingsProvider, ServicesProvider
Default implementation of the BindingsProvider and ServicesProvider interfaces.

Creates a binding that matches any present portType, and a service containing ports that match the bindings. Lets subclasses populate these through template methods. *

Since:
1.5.0
Author:
Arjen Poutsma
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    protected final org.apache.commons.logging.Log
    Logger available to subclasses.
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    addBindings(javax.wsdl.Definition definition)
    Creates a Binding for each PortType in the definition, and calls populateBinding(Definition,javax.wsdl.Binding) with it.
    void
    addServices(javax.wsdl.Definition definition)
    Creates a single Service if not present, and calls populateService(Definition, Service) with it.
    Returns the suffix to append to the port type name to obtain the binding name.
    Returns the service name.
    protected void
    populateBinding(javax.wsdl.Definition definition, javax.wsdl.Binding binding)
    Called after the Binding has been created, but before any sub-elements are added.
    protected void
    populateBindingFault(javax.wsdl.Definition definition, javax.wsdl.BindingFault bindingFault, javax.wsdl.Fault fault)
    Called after the BindingFault has been created.
    protected void
    populateBindingInput(javax.wsdl.Definition definition, javax.wsdl.BindingInput bindingInput, javax.wsdl.Input input)
    Called after the BindingInput has been created.
    protected void
    populateBindingOperation(javax.wsdl.Definition definition, javax.wsdl.BindingOperation bindingOperation)
    Called after the BindingOperation has been created, but before any sub-elements are added.
    protected void
    populateBindingOutput(javax.wsdl.Definition definition, javax.wsdl.BindingOutput bindingOutput, javax.wsdl.Output output)
    Called after the BindingOutput has been created.
    protected void
    populatePort(javax.wsdl.Definition definition, javax.wsdl.Port port)
    Called after the Port has been created, but before any sub-elements are added.
    protected void
    populateService(javax.wsdl.Definition definition, javax.wsdl.Service service)
    Called after the Service has been created, but before any sub-elements are added.
    void
    setBindingSuffix(String bindingSuffix)
    Sets the suffix to append to the port type name to obtain the binding name.
    void
    setServiceName(String serviceName)
    Sets the service name.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • logger

      protected final org.apache.commons.logging.Log logger
      Logger available to subclasses.
  • Constructor Details

    • DefaultConcretePartProvider

      public DefaultConcretePartProvider()
  • Method Details

    • getServiceName

      public String getServiceName()
      Returns the service name.
    • setServiceName

      public void setServiceName(String serviceName)
      Sets the service name.
    • getBindingSuffix

      public String getBindingSuffix()
      Returns the suffix to append to the port type name to obtain the binding name.
    • setBindingSuffix

      public void setBindingSuffix(String bindingSuffix)
      Sets the suffix to append to the port type name to obtain the binding name.
    • addBindings

      public void addBindings(javax.wsdl.Definition definition) throws javax.wsdl.WSDLException
      Creates a Binding for each PortType in the definition, and calls populateBinding(Definition,javax.wsdl.Binding) with it. Creates a BindingOperation for each Operation in the port type, a BindingInput for each Input in the operation, etc.

      Calls the various populate methods with the created WSDL4J objects.

      Specified by:
      addBindings in interface BindingsProvider
      Parameters:
      definition - the WSDL4J Definition
      Throws:
      javax.wsdl.WSDLException - in case of errors
      See Also:
    • populateBinding

      protected void populateBinding(javax.wsdl.Definition definition, javax.wsdl.Binding binding) throws javax.wsdl.WSDLException
      Called after the Binding has been created, but before any sub-elements are added. Subclasses can override this method to define the binding name, or add extensions to it.

      Default implementation sets the binding name to the port type name with the suffix appended to it.

      Parameters:
      definition - the WSDL4J Definition
      binding - the WSDL4J Binding
      Throws:
      javax.wsdl.WSDLException
    • populateBindingOperation

      protected void populateBindingOperation(javax.wsdl.Definition definition, javax.wsdl.BindingOperation bindingOperation) throws javax.wsdl.WSDLException
      Called after the BindingOperation has been created, but before any sub-elements are added. Subclasses can override this method to define the binding name, or add extensions to it.

      Default implementation sets the name of the binding operation to the name of the operation.

      Parameters:
      definition - the WSDL4J Definition
      bindingOperation - the WSDL4J BindingOperation
      Throws:
      javax.wsdl.WSDLException - in case of errors
    • populateBindingInput

      protected void populateBindingInput(javax.wsdl.Definition definition, javax.wsdl.BindingInput bindingInput, javax.wsdl.Input input) throws javax.wsdl.WSDLException
      Called after the BindingInput has been created. Subclasses can override this method to define the name, or add extensions to it.

      Default implementation set the name of the binding input to the name of the input.

      Parameters:
      definition - the WSDL4J Definition
      bindingInput - the WSDL4J BindingInput
      input - the corresponding WSDL4J Input @throws WSDLException in case of errors
      Throws:
      javax.wsdl.WSDLException
    • populateBindingOutput

      protected void populateBindingOutput(javax.wsdl.Definition definition, javax.wsdl.BindingOutput bindingOutput, javax.wsdl.Output output) throws javax.wsdl.WSDLException
      Called after the BindingOutput has been created. Subclasses can override this method to define the name, or add extensions to it.

      Default implementation sets the name of the binding output to the name of the output.

      Parameters:
      definition - the WSDL4J Definition
      bindingOutput - the WSDL4J BindingOutput
      output - the corresponding WSDL4J Output @throws WSDLException in case of errors
      Throws:
      javax.wsdl.WSDLException
    • populateBindingFault

      protected void populateBindingFault(javax.wsdl.Definition definition, javax.wsdl.BindingFault bindingFault, javax.wsdl.Fault fault) throws javax.wsdl.WSDLException
      Called after the BindingFault has been created. Subclasses can implement this method to define the name, or add extensions to it.

      Default implementation set the name of the binding fault to the name of the fault.

      Parameters:
      bindingFault - the WSDL4J BindingFault
      fault - the corresponding WSDL4J Fault @throws WSDLException in case of errors
      Throws:
      javax.wsdl.WSDLException
    • addServices

      public void addServices(javax.wsdl.Definition definition) throws javax.wsdl.WSDLException
      Creates a single Service if not present, and calls populateService(Definition, Service) with it. Creates a corresponding Port for each Binding, which is passed to populatePort(javax.wsdl.Definition,javax.wsdl.Port).
      Specified by:
      addServices in interface ServicesProvider
      Parameters:
      definition - the WSDL4J Definition
      Throws:
      javax.wsdl.WSDLException - in case of errors
    • populateService

      protected void populateService(javax.wsdl.Definition definition, javax.wsdl.Service service) throws javax.wsdl.WSDLException
      Called after the Service has been created, but before any sub-elements are added. Subclasses can implement this method to define the service name, or add extensions to it.

      Default implementation sets the name to the serviceName property.

      Parameters:
      service - the WSDL4J Service
      Throws:
      javax.wsdl.WSDLException - in case of errors
    • populatePort

      protected void populatePort(javax.wsdl.Definition definition, javax.wsdl.Port port) throws javax.wsdl.WSDLException
      Called after the Port has been created, but before any sub-elements are added. Subclasses can implement this method to define the port name, or add extensions to it.

      Default implementation sets the port name to the binding name.

      Parameters:
      definition - the WSDL4J Definition
      port - the WSDL4J Port
      Throws:
      javax.wsdl.WSDLException - in case of errors