| Modifier and Type | Field and Description |
|---|---|
| public ClassFile | |
| protected final Class | |
| public String | myClass
The name of the class to build. |
| pack-priv Set | |
| pack-priv Set | |
| protected final Class | |
| pack-priv Set |
| Access | Constructor and Description |
|---|---|
| public | ProxyMaker(String superclassName, Class<?> superclass)
Deprecated
- Use
ProxyMaker#ProxyMaker(String, Class, Class[])
Creates a proxy class maker that produces classes named
|
| public | ProxyMaker(String proxyClassName, Class<?> superclass, Class<?>... interfaces)
Creates a proxy class maker that produces classes named |
| Modifier and Type | Method and Description |
|---|---|
| protected void | |
| public void | |
| public void | |
| protected void | addConstructor(Class<?>[] parameters, int access)
Adds a constructor that calls through to superclass. |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | addMethod(String
of the java method name, String name of the python method to which the java method proxies (useful for clamped
objects) pyName, Class<?> return type ret, Class<?>[] parameter types parameters, Class<?>[] throwable exception types exceptions, int access, Class<?> declaringClass, ProxyCodeHelpers.method annotations methodAnnotations,parameter annotations parameterAnnotationsGenerates and adds a proxy method to the proxy class |
| protected void | |
| protected Code | addOpenConstructor(Constructor<?> constructor)
Adds a constructor that calls through to the superclass constructor with the same signature and leaves the returned Code open for more operations. |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | |
| protected void | callInitProxy(Class<?>[] parameters, Code code)
Calls __initProxy__ on this class with the given types of parameters, which must be available as arguments to the currently called method in the order of the parameters. |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | |
| private String | |
| protected void | |
| protected void | visitConstructor(Constructor<?> constructor)
Called for every constructor on the proxy's superclass that can be overridden by the proxy class. |
| protected void | |
| protected void | visitMethod(Method method)
Called for every method on the proxy's superclass and interfaces that can be overridden by the proxy class. |
| protected void | visitMethods(Class<?> klass)
Visits all methods declared on the given class and classes in its inheritance hierarchy. |
| protected void |
| classfile | back to summary |
|---|---|
| public ClassFile classfile | |
| interfaces | back to summary |
|---|---|
| protected final Class<?>[] interfaces | |
| myClass | back to summary |
|---|---|
| public String myClass The name of the class to build. | |
| names | back to summary |
|---|---|
| pack-priv Set<String> names | |
| namesAndSigs | back to summary |
|---|---|
| pack-priv Set<String> namesAndSigs | |
| superclass | back to summary |
|---|---|
| protected final Class<?> superclass | |
| supernames | back to summary |
|---|---|
| pack-priv Set<String> supernames | |
| ProxyMaker | back to summary |
|---|---|
| public ProxyMaker(String superclassName, Class<?> superclass)
Deprecated Creates a proxy class maker that produces classes named
| |
| ProxyMaker | back to summary |
|---|---|
| public ProxyMaker(String proxyClassName, Class<?> superclass, Class<?>... interfaces) Creates a proxy class maker that produces classes named | |
| addClassAnnotation | back to summary |
|---|---|
| protected void addClassAnnotation(ProxyCodeHelpers. | |
| addClassDictInit | back to summary |
|---|---|
| public void addClassDictInit() throws Exception | |
| addConstructor | back to summary |
|---|---|
| public void addConstructor(String name, Class<?>[] parameters, Class<?> ret, String sig, int access) throws Exception | |
| addConstructor | back to summary |
|---|---|
| protected void addConstructor(Class<?>[] parameters, int access) throws Exception Adds a constructor that calls through to superclass. | |
| addConstructorMethodCode | back to summary |
|---|---|
| public void addConstructorMethodCode(String pyName, Class<?>[] parameters, Class<?>[] exceptions, int access, Class<?> declaringClass, Code code) throws Exception A constructor that is also a method (!) | |
| addConstructors | back to summary |
|---|---|
| public void addConstructors(Class<?> c) throws Exception | |
| addMethod | back to summary |
|---|---|
| public void addMethod(Method method, int access) throws Exception | |
| addMethod | back to summary |
|---|---|
| public void addMethod(String name, Class<?> ret, Class<?>[] parameters, Class<?>[] exceptions, int access, Class<?> declaringClass) throws Exception Adds a method of the given name to the class being implemented. If
| |
| addMethod | back to summary |
|---|---|
| public void addMethod(String name, String pyName, Class<?> ret, Class<?>[] parameters, Class<?>[] exceptions, int access, Class<?> declaringClass, ProxyCodeHelpers. Generates and adds a proxy method to the proxy class
| |
| addMethods | back to summary |
|---|---|
| protected void addMethods(Class<?> c, Set<String> t) throws Exception | |
| addOpenConstructor | back to summary |
|---|---|
| protected Code addOpenConstructor(Constructor<?> constructor) throws Exception Adds a constructor that calls through to the superclass constructor with the same signature and leaves the returned Code open for more operations. The caller of this method must add a return to the Code. | |
| addProxy | back to summary |
|---|---|
| public void addProxy() throws Exception | |
| addSuperMethod | back to summary |
|---|---|
| public void addSuperMethod(Method method, int access) throws Exception | |
| addSuperMethod | back to summary |
|---|---|
| public void addSuperMethod(String methodName, String superName, String declClass, Class<?>[] parameters, Class<?> ret, String sig, int access) throws Exception | |
| build | back to summary |
|---|---|
| public void build(OutputStream out) throws Exception Builds this proxy and writes its bytecode to | |
| build | back to summary |
|---|---|
| public void build() throws Exception | |
| callInitProxy | back to summary |
|---|---|
| protected void callInitProxy(Class<?>[] parameters, Code code) throws Exception Calls __initProxy__ on this class with the given types of parameters, which must be available as arguments to the currently called method in the order of the parameters. | |
| callMethod | back to summary |
|---|---|
| public void callMethod(Code code, String name, Class<?>[] parameters, Class<?> ret, Class<?>[] exceptions) throws Exception | |
| callSuper | back to summary |
|---|---|
| public void callSuper(Code code, String name, String superclass, Class<?>[] parameters, Class<?> ret, boolean doReturn) throws Exception | |
| doConstants | back to summary |
|---|---|
| public void doConstants() throws Exception | |
| doJavaCall | back to summary |
|---|---|
| public void doJavaCall(Code code, String name, String type, String jcallName) throws Exception | |
| getArgs | back to summary |
|---|---|
| public void getArgs(Code code, Class<?>[] parameters) throws Exception | |
| methodString | back to summary |
|---|---|
| private String methodString(Method m) | |
| visitClassAnnotations | back to summary |
|---|---|
| protected void visitClassAnnotations() throws Exception | |
| visitConstructor | back to summary |
|---|---|
| protected void visitConstructor(Constructor<?> constructor) throws Exception Called for every constructor on the proxy's superclass that can be overridden by the proxy class. | |
| visitConstructors | back to summary |
|---|---|
| protected void visitConstructors() throws Exception Visits constructors from this proxy's superclass. | |
| visitMethod | back to summary |
|---|---|
| protected void visitMethod(Method method) throws Exception Called for every method on the proxy's superclass and interfaces that can be overridden by
the proxy class. If the proxy wants to perform Python lookup and calling,
| |
| visitMethods | back to summary |
|---|---|
| protected void visitMethods(Class<?> klass) throws Exception Visits all methods declared on the given class and classes in its inheritance hierarchy.
Methods visible to subclasses are added to | |
| visitMethods | back to summary |
|---|---|
| protected void visitMethods() throws Exception | |