private static void TestDynamicProxy() { var proxy = (ITest)SecurityInterceptor.Inject(new TargetClass()); proxy.TestFunctionOne(); proxy.TestFunctionTwo(new object(), new object()); }
private static void TestStaticProxy() { var handler = new SecurityInterceptor(new TargetClass()); var proxy = new TargetClassStaticProxy(handler, typeof(TargetClass)); proxy.TestFunctionOne(); proxy.TestFunctionTwo(new object(), new object()); }