dynamic proxy classes have many interesting uses within an application, one of which is to effectively handle pre- and post-method invocation operations in a uniform fashion.
动态代理类有许多应用程序中使用的接口,其中一个可以用统一的方式有效地处理方法前和方法后的调用操作。
dynamic proxy classes give us a way to easily handle validation on any method in a uniform way, while completely separating all of the validation logic from the core business logic.
动态代理类给了我们一种以统一方式方便地处理任何方法上的验证途径,同时把所有的验证逻辑完全与核心业务逻辑分离开。
method invocations on dynamic proxy classes do not perform nearly as well a direct method call on objects.
对动态代理类的方法调用,不会像直接调用对象的方法那样好。
dynamic proxy is a structural pattern that defines a set of classes and method invocations which are dispatched to an invocation handler that is specified when the dynamic proxy classes are generated.
动态代理是一种结构模式,它定义了一组类与方法调用,这些类和调用被分派给调用句柄(在动态代理类生成的时候指定)。
i can tie all this together with one final piece of code, which will actually create the dynamic proxy classes and attach the correct invocation handler to it.
我可以把所有这些捆绑在一起,形成最后的代码片断,这段代码会实际建立动态代理类,为它加上正确的调用处理程序。
using dynamic proxy classes for validation is a simple and effective way to decouple validation routines from your application's core business logic.
使用动态代理类进行验证是从应用程序的核心逻辑去耦验证程序的简单而有效的方法。
dynamic proxy classes have many uses within a business object framework other than simply validating methods in a uniform way.
动态代理类在业务对象框架中有许多用途,不仅仅是用一致的方式对方法进行验证。