-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathIDocumentation.cs
More file actions
53 lines (46 loc) · 2.16 KB
/
IDocumentation.cs
File metadata and controls
53 lines (46 loc) · 2.16 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
//*****************************************************************************
//* Code Factory SDK
//* Copyright (c) 2020 CodeFactory, LLC
//*****************************************************************************
using CodeFactory.DotNet.CSharp;
using System.Threading.Tasks;
namespace CodeFactory.DotNet
{
/// <summary>
/// Interface that determines if a model has code level documentation.
/// </summary>
public interface IDocumentation
{
/// <summary>
/// Flag that determines if the model has code level documentation assigned to it.
/// </summary>
bool HasDocumentation { get; }
/// <summary>
/// Documentation that has been assigned to this model.
/// </summary>
string Documentation { get; }
/// <summary>
/// Adds the supplied source code directly before the documentation.
/// </summary>
/// <param name="sourceCode">The target syntax to be added to the document.</param>
/// <returns>Updated <see cref="CsSource"/> model with the injected source code.</returns>
Task<CsSource> AddBeforeDocsAsync(string sourceCode);
/// <summary>
/// Adds the supplied source code directly after the documentation.
/// </summary>
/// <param name="sourceCode">The target syntax to be added to the document.</param>
/// <returns>Updated <see cref="CsSource"/> model with the injected source code.</returns>
Task<CsSource> AddAfterDocsAsync(string sourceCode);
/// <summary>
/// Replaces the supplied source code directly this the documentation.
/// </summary>
/// <param name="sourceCode">The target syntax to be added to the document.</param>
/// <returns>Updated <see cref="CsSource"/> model with the injected source code.</returns>
Task<CsSource> ReplaceDocsAsync(string sourceCode);
/// <summary>
/// Deletes the documentation from the target supporting code artifact.
/// </summary>
/// <returns>Updated <see cref="CsSource"/> model with the documentation removed.</returns>
Task<CsSource> DeleteDocsAsync();
}
}