Extension methods can only be declared in static classes.
扩展方法仅可声明在静态类中。
C 's method takes precedence over both extension methods.
的方法优先于两个扩展方法。
Dynamic lookup will not be able to find extension methods.
动态查找不能查找扩展方法。
Extension methods enable you to add methods to an existing class.
通过使用扩展方法,可以将方法添加到现有类中。
Extension methods have all the capabilities of regular static methods.
扩展方法具备所有常规静态方法的所有能力。
The compiler gives instance methods preference over extension methods.
编译器赋予实例方法的优先级高于扩展方法。
Use Extension methods to extend your functionality to existing base classes.
使用扩展方法扩展你的功能,现有的基类。
Translating queries into calls to an API also required the addition of extension methods.
将查询转换成对API的调用也需要添加扩展方法。
Extension methods are static methods that can be invoked using instance method syntax.
扩展方法是可以通过使用实例方法语法调用的静态方法。
Extension methods are static methods that can be invoked using instance method syntax.
是可以通过使用实例方法语法调用的静态方法。
You can use extension methods to extend a class or interface, but not to override them.
您可以使用扩展方法来扩展一个类或接口,但不是来覆盖。
Usually, the extension methods are written in the same language as that of the XSL processor.
通常,扩展方法是用和XSL处理器相同的语言编写的。
Extension Methods - Sometimes you want to take a private helper method and reuse it elsewhere.
扩展方法—有时候你会想要在任何地方都能重用某个私有的helper方法。
In addition, once imported, extension methods can be invoked using instance method syntax.
另外,一旦被导入,扩展方法可以使用实例方法语法调用之。
Another idea LINQ borrows, this time from dynamic languages, is the idea of "extension methods".
LINQ带来的另外一个概念“扩展方法”来源于动态语言。
Extension methods are less discoverable and more limited in functionality than instance methods.
扩展方法不容易被发现并且在功能上比实例方法更受限。
In some XSL processors, like Xalan, there are even extension methods written directly into the processor.
在某些XSL处理器中(如xalan),甚至有直接写到处理器中的扩展方法。
See Extension Methods (C# Programming Guide) with Binding Extension Methods at Compile Time for details.
看到扩展方法(C编程指南#)随着结合可拓方法在编译时详情。
Extension methods, which make it possible to extend existing types and constructed types with additional methods.
的方法扩展已存在的类型和构造类型成为可能。
In effect, extension methods make it possible to extend existing types and constructed types with additional methods.
效果上,扩展方法使得用附加的方法扩展已存在类型和构造类型成为可能。
Extension methods should be used to "add" overloads to interfaces. They can also be used to manage dependencies between libraries.
扩展方法应该用于为接口“添加”重载,也可以用于管理类库之间的依赖。
The ADO.NET team will make available a T4 template (not included in Beta) to generate classes and extension methods for ObjectContext.
NET小组会提供t 4模版(没有包含在Beta中)来生成objectcontext的类和扩展方法。
By adding this using directive you are indicating to the compiler that any extension methods in that namespace should be imported.
使用指令你指示编译器在命名空间应该进口任何扩展方法。
Extension methods are a way to allow a developer to extend an object (add new methods) without having to subclass or recompile that object.
扩展方法允许开发者扩展一个对象(添加新的方法),而不需要定义它的子类或者重新编译该对象。
For those reasons, it is recommended that extension methods be used sparingly and only in situations where instance methods are not feasible or possible.
由于这些原因,推荐保守地使用和仅在实例方法不可行或不可能的情况下使用。
Extension methods have all the capabilities of regular static methods. In addition, once imported, extension methods can be invoked using instance method syntax.
扩展方法具备所有常规静态方法的所有能力。另外,一旦被导入,扩展方法可以使用实例方法语法调用之。
One interesting feature that arises from deferred LINQ extension methods is that queries are evaluated from scratch every time the results are enumerated, as shown in Listing 5-31.
延迟LINQ扩展方法所引起的一个有趣的特性是每次枚举结果时都是从头开始评估的,如清单5 - 31所示。
One interesting feature that arises from deferred LINQ extension methods is that queries are evaluated from scratch every time the results are enumerated, as shown in Listing 5-31.
延迟LINQ扩展方法所引起的一个有趣的特性是每次枚举结果时都是从头开始评估的,如清单5 - 31所示。
应用推荐