org.simantics.databoard.method
Class MethodInterfaceUtil

java.lang.Object
  extended by org.simantics.databoard.method.MethodInterfaceUtil

public class MethodInterfaceUtil
extends java.lang.Object


Field Summary
static java.util.Comparator<java.lang.reflect.Method> methodComparator
           
 
Constructor Summary
MethodInterfaceUtil()
           
 
Method Summary
static MethodInterface adaptMethods(MethodInterface mi, MethodTypeDefinition[] rangeMethods)
           
static
<T> MethodInterface
bindInterface(java.lang.Class<T> interfaze, T obj)
          Bind an instance a to Method Interface
static
<T> MethodInterface
bindInterface(Interface interfaceType, T obj)
          Bind interface type to an instance
static
<T> T
createProxy(java.lang.Class<T> interfaze, MethodInterface mi)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

methodComparator

public static java.util.Comparator<java.lang.reflect.Method> methodComparator
Constructor Detail

MethodInterfaceUtil

public MethodInterfaceUtil()
Method Detail

bindInterface

public static <T> MethodInterface bindInterface(java.lang.Class<T> interfaze,
                                                T obj)
                                     throws BindingConstructionException
Bind an instance a to Method Interface

Type Parameters:
T -
Parameters:
interfaze -
obj -
Returns:
the method interface
Throws:
BindingConstructionException

bindInterface

public static <T> MethodInterface bindInterface(Interface interfaceType,
                                                T obj)
                                     throws BindingConstructionException
Bind interface type to an instance

Type Parameters:
T -
Parameters:
interfaceType -
obj -
Returns:
the method interface
Throws:
BindingConstructionException

createProxy

public static <T> T createProxy(java.lang.Class<T> interfaze,
                                MethodInterface mi)
                     throws BindingConstructionException
Throws:
BindingConstructionException

adaptMethods

public static MethodInterface adaptMethods(MethodInterface mi,
                                           MethodTypeDefinition[] rangeMethods)