Class MethodEndpoint

java.lang.Object
org.springframework.ws.server.endpoint.MethodEndpoint

public final class MethodEndpoint extends Object
Represents a bean method that will be invoked as part of an incoming Web service message.

Consists of a Method, and a bean Object.

Since:
1.0.0
Author:
Arjen Poutsma
  • Constructor Details

    • MethodEndpoint

      public MethodEndpoint(Object bean, Method method)
      Constructs a new method endpoint with the given bean and method.
      Parameters:
      bean - the object bean
      method - the method
    • MethodEndpoint

      public MethodEndpoint(Object bean, String methodName, Class<?>... parameterTypes) throws NoSuchMethodException
      Constructs a new method endpoint with the given bean, method name and parameters.
      Parameters:
      bean - the object bean
      methodName - the method name
      parameterTypes - the method parameter types
      Throws:
      NoSuchMethodException - when the method cannot be found
    • MethodEndpoint

      public MethodEndpoint(String beanName, org.springframework.beans.factory.BeanFactory beanFactory, Method method)
      Constructs a new method endpoint with the given bean name and method. The bean name will be lazily initialized when invoke(Object...) is called.
      Parameters:
      beanName - the bean name
      beanFactory - the bean factory to use for bean initialization
      method - the method
  • Method Details

    • getBean

      public Object getBean()
      Returns the object bean for this method endpoint.
    • getMethod

      public Method getMethod()
      Returns the method for this method endpoint.
    • getMethodParameters

      public org.springframework.core.MethodParameter[] getMethodParameters()
      Returns the method parameters for this method endpoint.
    • getReturnType

      public org.springframework.core.MethodParameter getReturnType()
      Returns the method return type, as MethodParameter.
    • invoke

      public Object invoke(Object... args) throws Exception
      Invokes this method endpoint with the given arguments.
      Parameters:
      args - the arguments
      Returns:
      the invocation result
      Throws:
      Exception - when the method invocation results in an exception
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object