Class PythonProxyHandler

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

    public class PythonProxyHandler
    extends java.lang.Object
    implements java.lang.reflect.InvocationHandler

    A PythonProxyHandler is used in place of a Python object. Python programs can send Python objects that implements a Java interface to the JVM: these Python objects are represented by dynamic proxies with a PythonProxyHandler.

    Author:
    Barthelemy Dagenais
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected void finalize()  
      java.lang.Object invoke​(java.lang.Object proxy, java.lang.reflect.Method method, java.lang.Object[] args)  
      • Methods inherited from class java.lang.Object

        clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • CALL_PROXY_COMMAND_NAME

        public static final java.lang.String CALL_PROXY_COMMAND_NAME
        See Also:
        Constant Field Values
      • GARBAGE_COLLECT_PROXY_COMMAND_NAME

        public static final java.lang.String GARBAGE_COLLECT_PROXY_COMMAND_NAME
        See Also:
        Constant Field Values
    • Constructor Detail

      • PythonProxyHandler

        public PythonProxyHandler​(java.lang.String id,
                                  Gateway gateway)
    • Method Detail

      • finalize

        protected void finalize()
                         throws java.lang.Throwable
        Overrides:
        finalize in class java.lang.Object
        Throws:
        java.lang.Throwable
      • invoke

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