Access keys

InterfaceProxyFactory

Kind of class: class
Inherits from: BasicClass
Implements:
Author: Simon Wacker
Classpath: org.as2lib.env.reflect.InterfaceProxyFactory
File last modified: Friday, 01 July 2005, 19:57:42
InterfaceProxyFacotry creates proxies for interfaces.
It can only be
used in conjunction with interfaces, not classes.

It offers a higher performance than the TypeProxyFactory which can
also be used with classes.

Summary

Instance methods
Instance methods inherited from BasicClass

Instance methods

createProxy

function createProxy (
interfaze:Function, handler:InvocationHandler)
Creates proxies for interfaces.

You can cast the returned proxy to the passed-in interfaze.

null will be returned if the passed-in interfaze is null
or undefined.

The returned proxy catches method invocations by using __resolve.

Note that also methods that are not declared on the passed-in interfaze
but that are invoked on the returned proxy, get forwarded to the passed-in
handler.

Parameters:
interfaze:
the interface to create the proxy for
handler :
the handler to invoke on method invocations on the returned proxy
Returns:
the created interface proxy