@joebigelow / wix / commits / 93692d43

Include the include files with the processed document

Rob Mensching committed Mar 1, 2019 at 16:43 UTC 93692d4306b0f6ab3f97aab1598785951ec7bc47
4 files changed +37 -2
src/WixToolset.Extensibility/BasePreprocessorExtension.cs
+1 -1
@@ -85,7 +85,7 @@ namespace WixToolset.Extensibility
85 /// <summary>
86 /// Called at the end of the preprocessing of a source file.
87 /// </summary>
88 - public virtual void PostPreprocess(XDocument document)
88 + public virtual void PostPreprocess(IPreprocessResult result)
89 {
90 }
91 }
src/WixToolset.Extensibility/Data/IIncludedFile.cs new
+21
@@ -0,0 +1,21 @@
1 +// Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information.
2 +
3 +namespace WixToolset.Extensibility.Data
4 +{
5 + using WixToolset.Data;
6 +
7 + public interface IIncludedFile
8 + {
9 + /// <summary>
10 + /// Gets the full path of the included file.
11 + /// </summary>
12 + /// <value>The full path of the included file.</value>
13 + string Path { get; set; }
14 +
15 + /// <summary>
16 + /// Gets the source line numbers.
17 + /// </summary>
18 + /// <value>The source line numbers.</value>
19 + SourceLineNumber SourceLineNumbers { get; set; }
20 + }
21 +}
src/WixToolset.Extensibility/Data/IPreprocessResult.cs new
+14
@@ -0,0 +1,14 @@
1 +// Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information.
2 +
3 +namespace WixToolset.Extensibility.Data
4 +{
5 + using System.Collections.Generic;
6 + using System.Xml.Linq;
7 +
8 + public interface IPreprocessResult
9 + {
10 + XDocument Document { get; set; }
11 +
12 + IEnumerable<IIncludedFile> IncludedFiles { get; set; }
13 + }
14 +}
src/WixToolset.Extensibility/IPreprocessorExtension.cs
+1 -1
@@ -53,6 +53,6 @@ namespace WixToolset.Extensibility
53 /// <summary>
54 /// Called at the end of the preprocessing of a source file.
55 /// </summary>
56 - void PostPreprocess(XDocument document);
56 + void PostPreprocess(IPreprocessResult result);
57 }
58 }