aboutsummaryrefslogtreecommitdiff
path: root/src/WixToolset.Core.WindowsInstaller/Bind/BindSummaryInfoCommand.cs
diff options
context:
space:
mode:
authorRob Mensching <rob@firegiant.com>2020-06-25 14:43:50 -0700
committerRob Mensching <rob@firegiant.com>2020-06-25 14:50:31 -0700
commit38afa9e7bc7eacc021f8805f607368a05751e3c3 (patch)
tree803b0a8d9a06a7d6f7c4df408437017ae21a883e /src/WixToolset.Core.WindowsInstaller/Bind/BindSummaryInfoCommand.cs
parent8968578d50858721317d410549a9f9b5c62bf1f7 (diff)
downloadwix-38afa9e7bc7eacc021f8805f607368a05751e3c3.tar.gz
wix-38afa9e7bc7eacc021f8805f607368a05751e3c3.tar.bz2
wix-38afa9e7bc7eacc021f8805f607368a05751e3c3.zip
The Great Tuple to Symbol Rename (tm)
Diffstat (limited to 'src/WixToolset.Core.WindowsInstaller/Bind/BindSummaryInfoCommand.cs')
-rw-r--r--src/WixToolset.Core.WindowsInstaller/Bind/BindSummaryInfoCommand.cs24
1 files changed, 12 insertions, 12 deletions
diff --git a/src/WixToolset.Core.WindowsInstaller/Bind/BindSummaryInfoCommand.cs b/src/WixToolset.Core.WindowsInstaller/Bind/BindSummaryInfoCommand.cs
index d5806fee..82688edf 100644
--- a/src/WixToolset.Core.WindowsInstaller/Bind/BindSummaryInfoCommand.cs
+++ b/src/WixToolset.Core.WindowsInstaller/Bind/BindSummaryInfoCommand.cs
@@ -6,7 +6,7 @@ namespace WixToolset.Core.WindowsInstaller.Bind
6 using System.Globalization; 6 using System.Globalization;
7 using System.Linq; 7 using System.Linq;
8 using WixToolset.Data; 8 using WixToolset.Data;
9 using WixToolset.Data.Tuples; 9 using WixToolset.Data.Symbols;
10 10
11 /// <summary> 11 /// <summary>
12 /// Binds the summary information table of a database. 12 /// Binds the summary information table of a database.
@@ -49,13 +49,13 @@ namespace WixToolset.Core.WindowsInstaller.Bind
49 var foundCreatingApplication = false; 49 var foundCreatingApplication = false;
50 var now = DateTime.Now.ToString("yyyy/MM/dd HH:mm:ss", CultureInfo.InvariantCulture); 50 var now = DateTime.Now.ToString("yyyy/MM/dd HH:mm:ss", CultureInfo.InvariantCulture);
51 51
52 foreach (var summaryInformationTuple in this.Section.Tuples.OfType<SummaryInformationTuple>()) 52 foreach (var summaryInformationSymbol in this.Section.Symbols.OfType<SummaryInformationSymbol>())
53 { 53 {
54 switch (summaryInformationTuple.PropertyId) 54 switch (summaryInformationSymbol.PropertyId)
55 { 55 {
56 case SummaryInformationType.Codepage: // PID_CODEPAGE 56 case SummaryInformationType.Codepage: // PID_CODEPAGE
57 // make sure the code page is an int and not a web name or null 57 // make sure the code page is an int and not a web name or null
58 var codepage = summaryInformationTuple.Value; 58 var codepage = summaryInformationSymbol.Value;
59 59
60 if (String.IsNullOrEmpty(codepage)) 60 if (String.IsNullOrEmpty(codepage))
61 { 61 {
@@ -63,11 +63,11 @@ namespace WixToolset.Core.WindowsInstaller.Bind
63 } 63 }
64 else 64 else
65 { 65 {
66 summaryInformationTuple.Value = Common.GetValidCodePage(codepage, false, false, summaryInformationTuple.SourceLineNumbers).ToString(CultureInfo.InvariantCulture); 66 summaryInformationSymbol.Value = Common.GetValidCodePage(codepage, false, false, summaryInformationSymbol.SourceLineNumbers).ToString(CultureInfo.InvariantCulture);
67 } 67 }
68 break; 68 break;
69 case SummaryInformationType.PackageCode: // PID_REVNUMBER 69 case SummaryInformationType.PackageCode: // PID_REVNUMBER
70 var packageCode = summaryInformationTuple.Value; 70 var packageCode = summaryInformationSymbol.Value;
71 71
72 if (SectionType.Module == this.Section.Type) 72 if (SectionType.Module == this.Section.Type)
73 { 73 {
@@ -76,7 +76,7 @@ namespace WixToolset.Core.WindowsInstaller.Bind
76 else if ("*" == packageCode) 76 else if ("*" == packageCode)
77 { 77 {
78 // set the revision number (package/patch code) if it should be automatically generated 78 // set the revision number (package/patch code) if it should be automatically generated
79 summaryInformationTuple.Value = Common.GenerateGuid(); 79 summaryInformationSymbol.Value = Common.GenerateGuid();
80 } 80 }
81 break; 81 break;
82 case SummaryInformationType.Created: 82 case SummaryInformationType.Created:
@@ -86,7 +86,7 @@ namespace WixToolset.Core.WindowsInstaller.Bind
86 foundLastSaveDataTime = true; 86 foundLastSaveDataTime = true;
87 break; 87 break;
88 case SummaryInformationType.WindowsInstallerVersion: 88 case SummaryInformationType.WindowsInstallerVersion:
89 this.InstallerVersion = summaryInformationTuple[SummaryInformationTupleFields.Value].AsNumber(); 89 this.InstallerVersion = summaryInformationSymbol[SummaryInformationSymbolFields.Value].AsNumber();
90 break; 90 break;
91 case SummaryInformationType.WordCount: 91 case SummaryInformationType.WordCount:
92 if (SectionType.Patch == this.Section.Type) 92 if (SectionType.Patch == this.Section.Type)
@@ -96,7 +96,7 @@ namespace WixToolset.Core.WindowsInstaller.Bind
96 } 96 }
97 else 97 else
98 { 98 {
99 var attributes = summaryInformationTuple[SummaryInformationTupleFields.Value].AsNumber(); 99 var attributes = summaryInformationSymbol[SummaryInformationSymbolFields.Value].AsNumber();
100 this.LongNames = (0 == (attributes & 1)); 100 this.LongNames = (0 == (attributes & 1));
101 this.Compressed = (2 == (attributes & 2)); 101 this.Compressed = (2 == (attributes & 2));
102 } 102 }
@@ -110,7 +110,7 @@ namespace WixToolset.Core.WindowsInstaller.Bind
110 // add a summary information row for the create time/date property if its not already set 110 // add a summary information row for the create time/date property if its not already set
111 if (!foundCreateDataTime) 111 if (!foundCreateDataTime)
112 { 112 {
113 this.Section.AddTuple(new SummaryInformationTuple(null) 113 this.Section.AddSymbol(new SummaryInformationSymbol(null)
114 { 114 {
115 PropertyId = SummaryInformationType.Created, 115 PropertyId = SummaryInformationType.Created,
116 Value = now, 116 Value = now,
@@ -120,7 +120,7 @@ namespace WixToolset.Core.WindowsInstaller.Bind
120 // add a summary information row for the last save time/date property if its not already set 120 // add a summary information row for the last save time/date property if its not already set
121 if (!foundLastSaveDataTime) 121 if (!foundLastSaveDataTime)
122 { 122 {
123 this.Section.AddTuple(new SummaryInformationTuple(null) 123 this.Section.AddSymbol(new SummaryInformationSymbol(null)
124 { 124 {
125 PropertyId = SummaryInformationType.LastSaved, 125 PropertyId = SummaryInformationType.LastSaved,
126 Value = now, 126 Value = now,
@@ -130,7 +130,7 @@ namespace WixToolset.Core.WindowsInstaller.Bind
130 // add a summary information row for the creating application property if its not already set 130 // add a summary information row for the creating application property if its not already set
131 if (!foundCreatingApplication) 131 if (!foundCreatingApplication)
132 { 132 {
133 this.Section.AddTuple(new SummaryInformationTuple(null) 133 this.Section.AddSymbol(new SummaryInformationSymbol(null)
134 { 134 {
135 PropertyId = SummaryInformationType.CreatingApplication, 135 PropertyId = SummaryInformationType.CreatingApplication,
136 Value = String.Format(CultureInfo.InvariantCulture, AppCommon.GetCreatingApplicationString()), 136 Value = String.Format(CultureInfo.InvariantCulture, AppCommon.GetCreatingApplicationString()),