ilog.rules.factory

Class IlrMethodInvocation

  • All Implemented Interfaces:
    ilog.rules.factory.IlrSourceElement, IlrStatement, java.io.Serializable


    public final class IlrMethodInvocation
    extends IlrNaryValue
    implements IlrStatement
    This class represents a method invocation of the rule language.

    Warning: Serialized objects of this class will not be compatible with future releases. The current serialization support is appropriate for short term storage or RMI between applications running the same version of IBM Decision Server.

    See Also:
    Serialized Form
    • Constructor Detail

      • IlrMethodInvocation

        public IlrMethodInvocation(IlrValue object)
        Constructs an invocation of a method on an object.
        Parameters:
        object - The invoked object of this method invocation.
      • IlrMethodInvocation

        public IlrMethodInvocation(IlrValue object,
                           java.lang.String methodName,
                           IlrValue[] arguments)
        Constructs an invocation of a method belonging to the object passed as the argument.
        Parameters:
        object - The invoked object of this method invocation.
        methodName - The name of the method.
        arguments - The arguments of the invocation.
      • IlrMethodInvocation

        public IlrMethodInvocation(IlrValue object,
                           java.lang.String methodName,
                           IlrValue[] arguments,
                           ilog.rules.factory.IlrReflectClass[] genericArgs)
        Constructs an invocation of a generic method belonging to the object passed as the argument.
        Parameters:
        object - The invoked object of this method invocation.
        methodName - The name of the method.
        arguments - The arguments of the invocation.
        genericArgs - The type arguments to use to instantiate the generic method.
      • IlrMethodInvocation

        public IlrMethodInvocation(IlrValue object,
                           java.lang.reflect.Method method,
                           IlrValue[] arguments)
        Constructs an invocation of a method belonging to the object passed as the argument.
        Parameters:
        object - The invoked object of this method invocation.
        method - A method.
        arguments - The arguments of this method.
    • Method Detail

      • setMethod

        public void setMethod(java.lang.String methodName)
        Sets a method for this method call. The method is introspected using the arguments that have been added previously.
        Parameters:
        methodName - The name of the method.
      • getObject

        public IlrValue getObject()
        Gets the object invoked by this method call.
        Returns:
        The invoked object of this method call.
      • getXOMMethod

        public IlrMethod getXOMMethod()
        Gets the method of this method call.
        Returns:
        The method of this method call.
      • getGenericArguments

        public ilog.rules.factory.IlrReflectClass[] getGenericArguments()
        Gets the type arguments for a generic method call.
        Returns:
        The type arguments.
      • getName

        public java.lang.String getName()
        Gets the method name of this method call.
        Returns:
        The method name of this method call.
      • getClassName

        public java.lang.String getClassName()
        Gets the fully-qualified name of the class which declares the method.
        Returns:
        The fully-qualified name of the class which declares the method.
      • getShortClassName

        public java.lang.String getShortClassName()
        Gets the short name of the class which declares the method.
        Returns:
        The short name of the class which declares the method.
      • exploreValue

        public java.lang.Object exploreValue(IlrFactoryExplorer explorer)
        Explores this method call as a value using a factory explorer.
        Specified by:
        exploreValue in class IlrValue
        Parameters:
        explorer - The factory explorer.
        Returns:
        An object, the result of the exploration, or null if the method does not return a value.
      • exploreStatement

        public java.lang.Object exploreStatement(IlrFactoryExplorer explorer)
        Explores this method call as a statement using a factory explorer.
        Specified by:
        exploreStatement in interface IlrStatement
        Parameters:
        explorer - The factory explorer.
        Returns:
        An object, the result of the exploration, or null if the method does not return a value.
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object

© Copyright IBM Corp. 1987, 2017