edu.rice.cs.dynamicjava.symbol
Class SpecialMethod

java.lang.Object
  extended by edu.rice.cs.dynamicjava.symbol.SpecialMethod
All Implemented Interfaces:
Access.Limited, DJMethod, Function
Direct Known Subclasses:
ArrayCloneMethod, GetClassMethod

public abstract class SpecialMethod
extends java.lang.Object
implements DJMethod

Abstract parent for special implicit methods. The evaluation details are handled here, allowing the implementation to be based on a method with a different signature.


Constructor Summary
SpecialMethod()
           
 
Method Summary
 DJMethod declaredSignature()
          Get the original declared method (prior to any substitutions, etc).
 java.lang.Object evaluate(java.lang.Object receiver, java.lang.Iterable<java.lang.Object> args, RuntimeBindings bindings, Options options)
          Invoke the method with the given parameters.
protected abstract  java.lang.reflect.Method implementation()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface edu.rice.cs.dynamicjava.symbol.DJMethod
accessibility, accessModule, declaringClass, isAbstract, isFinal, isStatic
 
Methods inherited from interface edu.rice.cs.dynamicjava.symbol.Function
declaredName, parameters, returnType, thrownTypes, typeParameters
 
Methods inherited from interface edu.rice.cs.dynamicjava.symbol.Access.Limited
declaredName
 

Constructor Detail

SpecialMethod

public SpecialMethod()
Method Detail

implementation

protected abstract java.lang.reflect.Method implementation()
                                                    throws java.lang.ClassNotFoundException,
                                                           java.lang.NoSuchMethodException
Throws:
java.lang.ClassNotFoundException
java.lang.NoSuchMethodException

declaredSignature

public DJMethod declaredSignature()
Description copied from interface: DJMethod
Get the original declared method (prior to any substitutions, etc).

Specified by:
declaredSignature in interface DJMethod

evaluate

public java.lang.Object evaluate(java.lang.Object receiver,
                                 java.lang.Iterable<java.lang.Object> args,
                                 RuntimeBindings bindings,
                                 Options options)
                          throws EvaluatorException
Description copied from interface: DJMethod
Invoke the method with the given parameters.

Specified by:
evaluate in interface DJMethod
Throws:
EvaluatorException