Class MethodCallFunction

  • All Implemented Interfaces:
    IFunction

    public class MethodCallFunction
    extends java.lang.Object
    implements IFunction
    Invoke a method on an object. Parameters: {object (null if static), parametervalues...]}
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected java.lang.reflect.Method method
      The method.
    • Constructor Summary

      Constructors 
      Constructor Description
      MethodCallFunction​(java.lang.reflect.Method method)
      Create a new function.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      AttributeSet getRelevantAttributes()
      Get the set of relevant attribute types.
      java.lang.Class getReturnType()
      Get the return type of this function.
      java.lang.Object invoke​(java.lang.Object[] paramvalues, IOAVState state)
      Invoke a function and return a value (optional).
      java.lang.String toString()
      Create a string representation.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Field Detail

      • method

        protected java.lang.reflect.Method method
        The method.
    • Constructor Detail

      • MethodCallFunction

        public MethodCallFunction​(java.lang.reflect.Method method)
        Create a new function.
    • Method Detail

      • invoke

        public java.lang.Object invoke​(java.lang.Object[] paramvalues,
                                       IOAVState state)
        Invoke a function and return a value (optional).
        Specified by:
        invoke in interface IFunction
        Parameters:
        paramvalues - The parameter values.
        state - The state.
        Returns:
        The function value.
      • getReturnType

        public java.lang.Class getReturnType()
        Get the return type of this function.
        Specified by:
        getReturnType in interface IFunction
      • getRelevantAttributes

        public AttributeSet getRelevantAttributes()
        Get the set of relevant attribute types.
        Specified by:
        getRelevantAttributes in interface IFunction
        Returns:
        The relevant attribute types.
      • toString

        public java.lang.String toString()
        Create a string representation.
        Overrides:
        toString in class java.lang.Object