net.ranides.assira.reflection
Class MethodPointer<T>

java.lang.Object
  extended by net.ranides.assira.generic.AnyFunction<T>
      extended by net.ranides.assira.reflection.MethodPointer<T>
All Implemented Interfaces:
Function<T,Object[]>

public final class MethodPointer<T>
extends AnyFunction<T>

Author:
ranides

Method Summary
 T apply(Object[] arguments)
          Bezstanowa metoda implementująca zachowanie funkcji.
 MethodPointer<T> bind(Object that)
           
static
<T> MethodPointer<T>
make(Object object, Class<T> rtype, Method method)
           
static
<T> MethodPointer<T>
make(Object object, Class<T> rtype, String method)
           
static MethodPointer<Object> make(Object object, Method method)
           
static MethodPointer<Object> make(Object object, String method)
           
 boolean matches(Object... arguments)
           
 boolean unbinded()
          Czy funkcja używa pierwszego z przekazanych argumentów jako this.
 
Methods inherited from class net.ranides.assira.generic.AnyFunction
call, safecall, safecall
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

apply

public T apply(Object[] arguments)
Description copied from interface: Function
Bezstanowa metoda implementująca zachowanie funkcji.

Może być interpretowana jako transformacja S -> T.

Returns:
See Also:
Runnable.run(), Callable.call()

bind

public MethodPointer<T> bind(Object that)
Overrides:
bind in class AnyFunction<T>

unbinded

public boolean unbinded()
Description copied from class: AnyFunction
Czy funkcja używa pierwszego z przekazanych argumentów jako this.

Overrides:
unbinded in class AnyFunction<T>
Returns:

matches

public boolean matches(Object... arguments)
Overrides:
matches in class AnyFunction<T>

make

public static MethodPointer<Object> make(Object object,
                                         String method)

make

public static <T> MethodPointer<T> make(Object object,
                                        Class<T> rtype,
                                        String method)

make

public static MethodPointer<Object> make(Object object,
                                         Method method)

make

public static <T> MethodPointer<T> make(Object object,
                                        Class<T> rtype,
                                        Method method)


Copyright © 2013. All Rights Reserved.