Class MethodCallingVisitor

All Implemented Interfaces:
Serializable, PicoVisitor

public class MethodCallingVisitor extends TraversalCheckingVisitor implements Serializable
A PicoVisitor implementation, that calls methods on the components of a specific type.
Author:
Aslak Hellesøy, Jörg Schaible
See Also:
  • Constructor Details

    • MethodCallingVisitor

      public MethodCallingVisitor(Method method, Class<?> ofType, Object[] arguments, boolean visitInInstantiationOrder)
      Construct a MethodCallingVisitor for a method with arguments.
      Parameters:
      method - the Method to invoke
      ofType - the type of the components, that will be invoked
      visitInInstantiationOrder - true if components are visited in instantiation order
      arguments - the arguments for the method invocation (may be null)
      Throws:
      NullPointerException - if method, or ofType is null
    • MethodCallingVisitor

      public MethodCallingVisitor(Method method, Class ofType, Object[] arguments)
      Construct a MethodCallingVisitor for standard methods visiting the component in instantiation order.
      Parameters:
      method - the method to invoke
      ofType - the type of the components, that will be invoked
      arguments - the arguments for the method invocation (may be null)
      Throws:
      NullPointerException - if method, or ofType is null
  • Method Details