org.omegahat.Environment.Language
Class StaticMethodAlias
java.lang.Object
|
+--org.omegahat.Environment.Language.StaticMethodAlias
- All Implemented Interfaces:
- Evaluable
- Direct Known Subclasses:
- MethodAlias
- public class StaticMethodAlias
- extends java.lang.Object
- implements Evaluable
|
Field Summary |
protected java.lang.reflect.Method |
method
The class' method for which this is an alias. |
|
Constructor Summary |
StaticMethodAlias()
Default constructor allowing the method to be specified later. |
StaticMethodAlias(java.lang.reflect.Method method)
Construct the alias with the given methods. |
|
Method Summary |
java.lang.Object |
eval(Evaluator evaluator)
Evaluate the method with no arguments. |
java.lang.Object |
eval(java.lang.Object[] args,
Evaluator evaluator)
Evaluate the method with the specified arguments |
java.lang.reflect.Method |
Method()
Retrieve the Method object for which this is an alias. |
java.lang.reflect.Method |
Method(java.lang.reflect.Method m)
Set the Method for which this is an alias. |
java.lang.Object |
This()
Returns null, the object associated with this method. |
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
method
protected java.lang.reflect.Method method
- The class' method for which this is an alias.
StaticMethodAlias
public StaticMethodAlias()
- Default constructor allowing the method to be specified later.
For use by derived classes.
StaticMethodAlias
public StaticMethodAlias(java.lang.reflect.Method method)
- Construct the alias with the given methods.
eval
public java.lang.Object eval(Evaluator evaluator)
throws java.lang.Throwable
- Evaluate the method with no arguments.
- Specified by:
eval in interface Evaluable
eval
public java.lang.Object eval(java.lang.Object[] args,
Evaluator evaluator)
throws java.lang.Throwable
- Evaluate the method with the specified arguments
- Specified by:
eval in interface Evaluable
Method
public java.lang.reflect.Method Method()
- Retrieve the Method object for which this is an alias.
Method
public java.lang.reflect.Method Method(java.lang.reflect.Method m)
- Set the Method for which this is an alias.
This
public java.lang.Object This()
- Returns null, the object associated with this method.
There is no object since this is static. Used
in the non-static version of this.
toString
public java.lang.String toString()
- Overrides:
toString in class java.lang.Object