Class ClosurePool.Proxy

java.lang.Object
com.kenai.jffi.ClosurePool.Proxy
Enclosing class:
ClosurePool

static final class ClosurePool.Proxy extends Object
This is a proxy passed to the native code, to be called by the native trampoline code.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    (package private) final CallContext
    Keep references to the return and parameter types so they do not get garbage collected until the closure does.
    (package private) Closure
     
    (package private) static final Method
     
  • Constructor Summary

    Constructors
    Constructor
    Description
    Proxy(CallContext callContext)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    private static Method
    Gets the Method to be invoked by native code
    void
    invoke(long retvalAddress, long paramAddress)
    Invoked by the native closure trampoline to execute the java side of the closure.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • METHOD

      static final Method METHOD
    • callContext

      final CallContext callContext
      Keep references to the return and parameter types so they do not get garbage collected until the closure does.
    • closure

      volatile Closure closure
  • Constructor Details

  • Method Details

    • getMethod

      private static Method getMethod()
      Gets the Method to be invoked by native code
      Returns:
      The method to be invoked by native code
    • invoke

      public void invoke(long retvalAddress, long paramAddress)
      Invoked by the native closure trampoline to execute the java side of the closure.
      Parameters:
      retvalAddress - The address of the native return value buffer
      paramAddress - The address of the native parameter buffer.