ICodeInjectionService.CreateMethod 方法
使用指定的签名创建方法。
命名空间: Microsoft.Windows.Design.Services
程序集: Microsoft.Windows.Design.Interaction(在 Microsoft.Windows.Design.Interaction.dll 中)
语法
声明
Function CreateMethod ( _
method As CodeMemberMethod _
) As Boolean
bool CreateMethod(
CodeMemberMethod method
)
bool CreateMethod(
CodeMemberMethod^ method
)
abstract CreateMethod :
method:CodeMemberMethod -> bool
function CreateMethod(
method : CodeMemberMethod
) : boolean
参数
- method
类型:System.CodeDom.CodeMemberMethod
一个指定签名的 CodeMemberMethod。
返回值
类型:System.Boolean
如果已创建方法,则该值为 true;否则该值为 false。
备注
如果方法名称不唯一,则 CreateMethod 返回 false。
.NET Framework 安全性
- 对直接调用方的完全信任。此成员不能由部分信任的代码使用。有关更多信息,请参见通过部分受信任的代码使用库。