diff options
author | Bob Arnson <bob@firegiant.com> | 2020-03-24 13:49:28 -0400 |
---|---|---|
committer | Bob Arnson <bob@firegiant.com> | 2020-03-24 13:52:05 -0400 |
commit | c1ebab9485256e5fbf4f47d20be8627fd03c68a1 (patch) | |
tree | e02cbb480ad545cae1af727f9c025cd3c33a812d | |
parent | 9240b527b9b204764830b578ef41a5b880a0bda4 (diff) | |
download | wix-c1ebab9485256e5fbf4f47d20be8627fd03c68a1.tar.gz wix-c1ebab9485256e5fbf4f47d20be8627fd03c68a1.tar.bz2 wix-c1ebab9485256e5fbf4f47d20be8627fd03c68a1.zip |
Add XmlWriter overload.
- Also fix some typos.
-rw-r--r-- | src/WixToolset.Data/WindowsInstaller/Rows/PropertyRow.cs | 8 | ||||
-rw-r--r-- | src/WixToolset.Data/WindowsInstaller/WindowsInstallerData.cs | 15 |
2 files changed, 16 insertions, 7 deletions
diff --git a/src/WixToolset.Data/WindowsInstaller/Rows/PropertyRow.cs b/src/WixToolset.Data/WindowsInstaller/Rows/PropertyRow.cs index ad5197d9..3aba5de6 100644 --- a/src/WixToolset.Data/WindowsInstaller/Rows/PropertyRow.cs +++ b/src/WixToolset.Data/WindowsInstaller/Rows/PropertyRow.cs | |||
@@ -3,12 +3,12 @@ | |||
3 | namespace WixToolset.Data.WindowsInstaller.Rows | 3 | namespace WixToolset.Data.WindowsInstaller.Rows |
4 | { | 4 | { |
5 | /// <summary> | 5 | /// <summary> |
6 | /// Specialization of a row for the upgrade table. | 6 | /// Specialization of a row for the Property table. |
7 | /// </summary> | 7 | /// </summary> |
8 | public sealed class PropertyRow : Row | 8 | public sealed class PropertyRow : Row |
9 | { | 9 | { |
10 | /// <summary> | 10 | /// <summary> |
11 | /// Creates an Upgrade row that belongs to a table. | 11 | /// Creates an Property row that belongs to a table. |
12 | /// </summary> | 12 | /// </summary> |
13 | /// <param name="sourceLineNumbers">Original source lines for this row.</param> | 13 | /// <param name="sourceLineNumbers">Original source lines for this row.</param> |
14 | /// <param name="table">Table this Upgrade row belongs to and should get its column definitions from.</param> | 14 | /// <param name="table">Table this Upgrade row belongs to and should get its column definitions from.</param> |
@@ -18,7 +18,7 @@ namespace WixToolset.Data.WindowsInstaller.Rows | |||
18 | } | 18 | } |
19 | 19 | ||
20 | /// <summary> | 20 | /// <summary> |
21 | /// Gets and sets the upgrade code for the row. | 21 | /// Gets and sets the property name for the row. |
22 | /// </summary> | 22 | /// </summary> |
23 | /// <value>Property identifier for the row.</value> | 23 | /// <value>Property identifier for the row.</value> |
24 | public string Property | 24 | public string Property |
@@ -28,7 +28,7 @@ namespace WixToolset.Data.WindowsInstaller.Rows | |||
28 | } | 28 | } |
29 | 29 | ||
30 | /// <summary> | 30 | /// <summary> |
31 | /// Gets and sets the value for the row. | 31 | /// Gets and sets the property value for the row. |
32 | /// </summary> | 32 | /// </summary> |
33 | /// <value>Property value for the row.</value> | 33 | /// <value>Property value for the row.</value> |
34 | public string Value | 34 | public string Value |
diff --git a/src/WixToolset.Data/WindowsInstaller/WindowsInstallerData.cs b/src/WixToolset.Data/WindowsInstaller/WindowsInstallerData.cs index 43c19d69..e30be598 100644 --- a/src/WixToolset.Data/WindowsInstaller/WindowsInstallerData.cs +++ b/src/WixToolset.Data/WindowsInstaller/WindowsInstallerData.cs | |||
@@ -85,13 +85,22 @@ namespace WixToolset.Data.WindowsInstaller | |||
85 | { | 85 | { |
86 | using (var writer = XmlWriter.Create(wixout.CreateDataStream(WixOutputStreamName))) | 86 | using (var writer = XmlWriter.Create(wixout.CreateDataStream(WixOutputStreamName))) |
87 | { | 87 | { |
88 | writer.WriteStartDocument(); | 88 | this.Save(writer); |
89 | this.Write(writer); | ||
90 | writer.WriteEndDocument(); | ||
91 | } | 89 | } |
92 | } | 90 | } |
93 | 91 | ||
94 | /// <summary> | 92 | /// <summary> |
93 | /// Saves an output to an <c>XmlWriter</c>. | ||
94 | /// </summary> | ||
95 | /// <param name="wixout">XmlWriter to save to.</param> | ||
96 | public void Save(XmlWriter writer) | ||
97 | { | ||
98 | writer.WriteStartDocument(); | ||
99 | this.Write(writer); | ||
100 | writer.WriteEndDocument(); | ||
101 | } | ||
102 | |||
103 | /// <summary> | ||
95 | /// Gets table by name. | 104 | /// Gets table by name. |
96 | /// </summary> | 105 | /// </summary> |
97 | public bool TryGetTable(string tableName, out Table table) => this.Tables.TryGetTable(tableName, out table); | 106 | public bool TryGetTable(string tableName, out Table table) => this.Tables.TryGetTable(tableName, out table); |