Class NativeInvocationHandler

  • All Implemented Interfaces:
    java.lang.reflect.InvocationHandler

    public class NativeInvocationHandler
    extends java.lang.Object
    implements java.lang.reflect.InvocationHandler
    InvocationHandler used to map invocations on a java interface to the correct native function.
    • Constructor Summary

      Constructors 
      Constructor Description
      NativeInvocationHandler​(java.util.Map<java.lang.reflect.Method,​Invoker> invokers)
      Creates a new InvocationHandler instance.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.Object invoke​(java.lang.Object self, java.lang.reflect.Method method, java.lang.Object[] argArray)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • NativeInvocationHandler

        public NativeInvocationHandler​(java.util.Map<java.lang.reflect.Method,​Invoker> invokers)
        Creates a new InvocationHandler instance.
        Parameters:
        invokers - A map of method invokers
    • Method Detail

      • invoke

        public java.lang.Object invoke​(java.lang.Object self,
                                       java.lang.reflect.Method method,
                                       java.lang.Object[] argArray)
                                throws java.lang.Throwable
        Specified by:
        invoke in interface java.lang.reflect.InvocationHandler
        Throws:
        java.lang.Throwable