AssemblyBuilder.AddCodeCompileUnit(BuildProvider, CodeCompileUnit) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Adds source code for the assembly in the form of a CodeDOM graph.
public:
void AddCodeCompileUnit(System::Web::Compilation::BuildProvider ^ buildProvider, System::CodeDom::CodeCompileUnit ^ compileUnit);
public void AddCodeCompileUnit (System.Web.Compilation.BuildProvider buildProvider, System.CodeDom.CodeCompileUnit compileUnit);
member this.AddCodeCompileUnit : System.Web.Compilation.BuildProvider * System.CodeDom.CodeCompileUnit -> unit
Public Sub AddCodeCompileUnit (buildProvider As BuildProvider, compileUnit As CodeCompileUnit)
Parameters
- buildProvider
- BuildProvider
The build provider generating compileUnit
.
- compileUnit
- CodeCompileUnit
The code compile unit to include in the assembly compilation.
Remarks
A BuildProvider implementation calls the AddCodeCompileUnit method when generating a CodeDOM graph for a virtual path. Source code added with AddCodeCompileUnit is included in the assembly compilation.
Typically, a build provider's GenerateCode method implementation reads the VirtualPath property, parses the contents, and then adds the generated source code to the specified AssemblyBuilder object. The build provider uses the AddCodeCompileUnit method to add source code as a CodeDOM graph to the assembly. Alternately, the build provider can use the CreateCodeFile method to add source code as a physical file to the assembly.
Applies to
See also
.NET
フィードバック
https://aka.ms/ContentUserFeedback」を参照してください。
以下は間もなく提供いたします。2024 年を通じて、コンテンツのフィードバック メカニズムとして GitHub の issue を段階的に廃止し、新しいフィードバック システムに置き換えます。 詳細については、「フィードバックの送信と表示