"景先生毕设|www.jxszl.com

C# CodeGenerationOptions类代码示例

2023-12-29 17:45编辑: www.jxszl.com景先生毕设
本文整理汇总了C#中CodeGenerationOptions类的典型用法代码示例。如果您正苦于以下问题:C#CodeGenerationOptions类的具体用法?C#CodeGenerationOptions怎么用?C#CodeGenerationOptions使用的例子?这里精选的类代码示例或许可以为您提供帮助。 示例1:SchemaImporter internalSchemaImporter(XmlSchemasschemas,CodeGenerationOptionsoptions,CodeDomProvidercodeProvider,System.Xml.Serialization.ImportContextcontext) { if(!schemas.Contains("http://www.w3.org/2001/XMLSchema")) { schemas.AddReference(XmlSchemas.XsdSchema); schemas.SchemaSet.Add(XmlSchemas.XsdSchema); } if(!schemas.Contains("http://www.w3.org/XML/1998/namespace")) { schemas.AddReference(XmlSchemas.XmlSchema); schemas.SchemaSet.Add(XmlSchemas.XmlSchema); } this.schemas=schemas; this.options=options; this.codeProvider=codeProvider; this.context=context; this.Schemas.SetCache(this.Context.Cache,this.Context.ShareTypes); SchemaImporterExtensionsSectionsection=System.Configuration.PrivilegedConfigurationManager.GetSection(ConfigurationStrings.SchemaImporterExtensionsSectionPath)asSchemaImporterExtensionsSection; if(section!=null) { this.extensions=section.SchemaImporterExtensionsInternal; } else { this.extensions=newSchemaImporterExtensionCollection(); } }
原文链接:http://www.jxszl.com/biancheng/C/556801.html