Member group
AddDocument
Declaring type: Project
Namespace: Raven.CodeAnalysis
Assembly: Raven.CodeAnalysis.dll
Source file: Project.cs
Overloads / Variants
AddDocument
func AddDocument(id: DocumentId, name: string, text: SourceText, filePath: string? = null) -> Document
Source file: Project.cs
Adds a new document to this project and returns the resulting Raven.CodeAnalysis.Document.
Parameters
| Name | Type | Description |
|---|---|---|
id |
DocumentId | |
name |
String | |
text |
SourceText | |
filePath |
String? |
Return value
Remarks
The returned document belongs to a new Raven.CodeAnalysis.Project.Solution that contains the added document. To update a Raven.CodeAnalysis.Workspace, apply the returned document's solution via workspace.TryApplyChanges(document.Project.Solution).
AddDocument
func AddDocument(name: string, text: SourceText, filePath: string? = null) -> Document
Source file: Project.cs
Adds a new document with an automatically generated identifier.
Parameters
| Name | Type | Description |
|---|---|---|
name |
String | |
text |
SourceText | |
filePath |
String? |