Example #1
0
 /// <summary>
 /// Creates a ProxyInterceptor based on given interface interfaceType due to limitations of Castle's Dynamic ProxyInterceptor.
 /// </summary>
 /// <param name="interfaceType">Interface Type to proxy</param>
 /// <param name="proxyInterceptor">ProxyInterceptor Object</param>
 /// <param name="target">ProxyInterceptor Default Target</param>
 /// <returns>Transparent ProxyInterceptor</returns>
 public object CreateTransparentInterfaceProxy(Type interfaceType, out ProxyInterceptor proxyInterceptor, object target = null)
 {
     return(proxyGenerator.CreateInterfaceProxyWithTargetInterface(
                interfaceType,
                target,
                proxyInterceptor = new ProxyInterceptor()));
 }
Example #2
0
 /// <summary>
 /// Creates a ProxyInterceptor based on given interface interfaceType due to limitations of Castle's Dynamic ProxyInterceptor.
 /// </summary>
 /// <param name="interfaceType">Interface Type to proxy</param>
 /// <param name="proxyInterceptor">ProxyInterceptor Object</param>
 /// <param name="target">ProxyInterceptor Default Target</param>
 /// <returns>Transparent ProxyInterceptor</returns>
 public object CreateTransparentInterfaceProxy(Type interfaceType, out ProxyInterceptor proxyInterceptor, object target = null)
 {
     return proxyGenerator.CreateInterfaceProxyWithTargetInterface(
         interfaceType,
         target,
         proxyInterceptor = new ProxyInterceptor());
 }