public virtual object CreateCustomClassProxy(Type baseClass, IInterceptor interceptor, GeneratorContext context, params object[] argumentsForConstructor) { return(CreateCustomClassProxy(baseClass, interceptor, context, true, argumentsForConstructor)); }
/// <summary> /// /// </summary> /// <param name="interfaces"></param> /// <param name="interceptor"></param> /// <param name="context"></param> /// <param name="target">The proxy target.</param> /// <returns></returns> public virtual object CreateCustomProxy(Type[] interfaces, IInterceptor interceptor, object target, GeneratorContext context) { AssertUtil.IsInterface(interfaces, "interfaces"); AssertUtil.NotNull(interceptor, "interceptor"); AssertUtil.NotNull(target, "target"); AssertUtil.NotNull(context, "context"); Type newType = ProxyBuilder.CreateCustomInterfaceProxy(interfaces, target.GetType(), context); return(CreateCustomProxyInstance(newType, interceptor, target, context)); }
protected virtual object CreateCustomClassProxyInstance(Type type, IInterceptor interceptor, GeneratorContext context, object target) { return(CreateProxyInstance(type, interceptor, target)); }
/// <summary> /// /// </summary> /// <param name="theInterface"></param> /// <param name="interceptor"></param> /// <param name="context"></param> /// <param name="target">The proxy target.</param> /// <returns></returns> public virtual object CreateCustomProxy(Type theInterface, IInterceptor interceptor, object target, GeneratorContext context) { return(CreateCustomProxy(new Type[] { theInterface }, interceptor, target, context)); }