本文整理汇总了VB.NET中System.CodeDom.Compiler.CompilerInfo.CreateDefaultCompilerParameters方法的典型用法代码示例。如果您正苦于以下问题:VB.NET CompilerInfo.CreateDefaultCompilerParameters方法的具体用法?VB.NET CompilerInfo.CreateDefaultCompilerParameters怎么用?VB.NET CompilerInfo.CreateDefaultCompilerParameters使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类System.CodeDom.Compiler.CompilerInfo
的用法示例。
在下文中一共展示了CompilerInfo.CreateDefaultCompilerParameters方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的VB.NET代码示例。
示例1: CType
Dim info As CompilerInfo = CodeDomProvider.GetCompilerInfo(configLanguage)
' Check whether there is a provider configured for this language.
If info.IsCodeDomProviderTypeValid Then
' Get a provider instance using the configured type information.
Dim provider As CodeDomProvider
provider = CType(Activator.CreateInstance(info.CodeDomProviderType), CodeDomProvider)
' Display information about this language provider.
Console.WriteLine("Language provider: {0}", _
provider.ToString())
Console.WriteLine()
Console.WriteLine(" Default file extension: {0}", _
provider.FileExtension)
Console.WriteLine()
' Get the compiler settings for this language.
Dim langCompilerConfig As CompilerParameters = info.CreateDefaultCompilerParameters()
Console.WriteLine(" Compiler options: {0}", _
langCompilerConfig.CompilerOptions)
Console.WriteLine(" Compiler warning level: {0}", _
langCompilerConfig.WarningLevel)
Else
' Tell the user that the language provider was not found.
Console.WriteLine("There is no provider configured for input language ""{0}"".", configLanguage)
End If
开发者ID:VB.NET开发者,项目名称:System.CodeDom.Compiler,代码行数:27,代码来源:CompilerInfo.CreateDefaultCompilerParameters