Solution.AddDocument 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.
Overloads
AddDocument(DocumentId, String, SyntaxNode, IEnumerable<String>, String, Boolean, PreservationMode) |
Creates a new solution instance with the corresponding project updated to include a new document instance defined by its name and root SyntaxNode. |
AddDocument(DocumentId, String, SourceText, IEnumerable<String>, String, Boolean) |
Creates a new solution instance with the corresponding project updated to include a new document instance defined by its name and text. |
AddDocument(DocumentInfo) |
Create a new solution instance with the corresponding project updated to include a new document instanced defined by the document info. |
AddDocument(DocumentId, String, TextLoader, IEnumerable<String>) |
Creates a new solution instance with the project updated to include a new document with the arguments specified. |
AddDocument(DocumentId, String, String, IEnumerable<String>, String) |
Creates a new solution instance with the corresponding project updated to include a new document instance defined by its name and text. |
AddDocument(DocumentId, String, SyntaxNode, IEnumerable<String>, String, Boolean, PreservationMode)
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
Creates a new solution instance with the corresponding project updated to include a new document instance defined by its name and root SyntaxNode.
public Microsoft.CodeAnalysis.Solution AddDocument (Microsoft.CodeAnalysis.DocumentId documentId, string name, Microsoft.CodeAnalysis.SyntaxNode syntaxRoot, System.Collections.Generic.IEnumerable<string> folders = default, string filePath = default, bool isGenerated = false, Microsoft.CodeAnalysis.PreservationMode preservationMode = Microsoft.CodeAnalysis.PreservationMode.PreserveValue);
public Microsoft.CodeAnalysis.Solution AddDocument (Microsoft.CodeAnalysis.DocumentId documentId, string name, Microsoft.CodeAnalysis.SyntaxNode syntaxRoot, System.Collections.Generic.IEnumerable<string>? folders = default, string? filePath = default, bool isGenerated = false, Microsoft.CodeAnalysis.PreservationMode preservationMode = Microsoft.CodeAnalysis.PreservationMode.PreserveValue);
member this.AddDocument : Microsoft.CodeAnalysis.DocumentId * string * Microsoft.CodeAnalysis.SyntaxNode * seq<string> * string * bool * Microsoft.CodeAnalysis.PreservationMode -> Microsoft.CodeAnalysis.Solution
Public Function AddDocument (documentId As DocumentId, name As String, syntaxRoot As SyntaxNode, Optional folders As IEnumerable(Of String) = Nothing, Optional filePath As String = Nothing, Optional isGenerated As Boolean = false, Optional preservationMode As PreservationMode = Microsoft.CodeAnalysis.PreservationMode.PreserveValue) As Solution
Parameters
- documentId
- DocumentId
- name
- String
- syntaxRoot
- SyntaxNode
- folders
- IEnumerable<String>
- filePath
- String
- isGenerated
- Boolean
- preservationMode
- PreservationMode
Returns
Applies to
AddDocument(DocumentId, String, SourceText, IEnumerable<String>, String, Boolean)
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
Creates a new solution instance with the corresponding project updated to include a new document instance defined by its name and text.
public Microsoft.CodeAnalysis.Solution AddDocument (Microsoft.CodeAnalysis.DocumentId documentId, string name, Microsoft.CodeAnalysis.Text.SourceText text, System.Collections.Generic.IEnumerable<string> folders = default, string filePath = default, bool isGenerated = false);
public Microsoft.CodeAnalysis.Solution AddDocument (Microsoft.CodeAnalysis.DocumentId documentId, string name, Microsoft.CodeAnalysis.Text.SourceText text, System.Collections.Generic.IEnumerable<string>? folders = default, string? filePath = default, bool isGenerated = false);
member this.AddDocument : Microsoft.CodeAnalysis.DocumentId * string * Microsoft.CodeAnalysis.Text.SourceText * seq<string> * string * bool -> Microsoft.CodeAnalysis.Solution
Public Function AddDocument (documentId As DocumentId, name As String, text As SourceText, Optional folders As IEnumerable(Of String) = Nothing, Optional filePath As String = Nothing, Optional isGenerated As Boolean = false) As Solution
Parameters
- documentId
- DocumentId
- name
- String
- text
- SourceText
- folders
- IEnumerable<String>
- filePath
- String
- isGenerated
- Boolean
Returns
Applies to
AddDocument(DocumentInfo)
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
Create a new solution instance with the corresponding project updated to include a new document instanced defined by the document info.
public:
Microsoft::CodeAnalysis::Solution ^ AddDocument(Microsoft::CodeAnalysis::DocumentInfo ^ documentInfo);
public Microsoft.CodeAnalysis.Solution AddDocument (Microsoft.CodeAnalysis.DocumentInfo documentInfo);
member this.AddDocument : Microsoft.CodeAnalysis.DocumentInfo -> Microsoft.CodeAnalysis.Solution
Public Function AddDocument (documentInfo As DocumentInfo) As Solution
Parameters
- documentInfo
- DocumentInfo
Returns
Applies to
AddDocument(DocumentId, String, TextLoader, IEnumerable<String>)
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
Creates a new solution instance with the project updated to include a new document with the arguments specified.
public Microsoft.CodeAnalysis.Solution AddDocument (Microsoft.CodeAnalysis.DocumentId documentId, string name, Microsoft.CodeAnalysis.TextLoader loader, System.Collections.Generic.IEnumerable<string> folders = default);
public Microsoft.CodeAnalysis.Solution AddDocument (Microsoft.CodeAnalysis.DocumentId documentId, string name, Microsoft.CodeAnalysis.TextLoader loader, System.Collections.Generic.IEnumerable<string>? folders = default);
member this.AddDocument : Microsoft.CodeAnalysis.DocumentId * string * Microsoft.CodeAnalysis.TextLoader * seq<string> -> Microsoft.CodeAnalysis.Solution
Public Function AddDocument (documentId As DocumentId, name As String, loader As TextLoader, Optional folders As IEnumerable(Of String) = Nothing) As Solution
Parameters
- documentId
- DocumentId
- name
- String
- loader
- TextLoader
- folders
- IEnumerable<String>
Returns
Applies to
AddDocument(DocumentId, String, String, IEnumerable<String>, String)
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
- Source:
- Solution.cs
Creates a new solution instance with the corresponding project updated to include a new document instance defined by its name and text.
public Microsoft.CodeAnalysis.Solution AddDocument (Microsoft.CodeAnalysis.DocumentId documentId, string name, string text, System.Collections.Generic.IEnumerable<string> folders = default, string filePath = default);
public Microsoft.CodeAnalysis.Solution AddDocument (Microsoft.CodeAnalysis.DocumentId documentId, string name, string text, System.Collections.Generic.IEnumerable<string>? folders = default, string? filePath = default);
member this.AddDocument : Microsoft.CodeAnalysis.DocumentId * string * string * seq<string> * string -> Microsoft.CodeAnalysis.Solution
Public Function AddDocument (documentId As DocumentId, name As String, text As String, Optional folders As IEnumerable(Of String) = Nothing, Optional filePath As String = Nothing) As Solution
Parameters
- documentId
- DocumentId
- name
- String
- text
- String
- folders
- IEnumerable<String>
- filePath
- String