diff options
| author | Rob Mensching <rob@firegiant.com> | 2019-10-07 07:32:59 -0700 |
|---|---|---|
| committer | Rob Mensching <rob@firegiant.com> | 2019-10-07 11:27:21 -0700 |
| commit | cece10e037c6daacc8d2def1a9057882aec47fe4 (patch) | |
| tree | 8e79c0d5b30ed8e663c077b2d9ce2b829b76ab84 /src/WixToolset.Data/Tuples/WixBundlePayloadTuple.cs | |
| parent | 7462108b714d07161126dcedda5312daef54ae13 (diff) | |
| download | wix-cece10e037c6daacc8d2def1a9057882aec47fe4.tar.gz wix-cece10e037c6daacc8d2def1a9057882aec47fe4.tar.bz2 wix-cece10e037c6daacc8d2def1a9057882aec47fe4.zip | |
Add support for long fields and fix up Bundle and many other tuples
Diffstat (limited to 'src/WixToolset.Data/Tuples/WixBundlePayloadTuple.cs')
| -rw-r--r-- | src/WixToolset.Data/Tuples/WixBundlePayloadTuple.cs | 42 |
1 files changed, 17 insertions, 25 deletions
diff --git a/src/WixToolset.Data/Tuples/WixBundlePayloadTuple.cs b/src/WixToolset.Data/Tuples/WixBundlePayloadTuple.cs index 5eb4a987..049ac3b5 100644 --- a/src/WixToolset.Data/Tuples/WixBundlePayloadTuple.cs +++ b/src/WixToolset.Data/Tuples/WixBundlePayloadTuple.cs | |||
| @@ -10,7 +10,6 @@ namespace WixToolset.Data | |||
| 10 | TupleDefinitionType.WixBundlePayload, | 10 | TupleDefinitionType.WixBundlePayload, |
| 11 | new[] | 11 | new[] |
| 12 | { | 12 | { |
| 13 | new IntermediateFieldDefinition(nameof(WixBundlePayloadTupleFields.WixBundlePayload), IntermediateFieldType.String), | ||
| 14 | new IntermediateFieldDefinition(nameof(WixBundlePayloadTupleFields.Name), IntermediateFieldType.String), | 13 | new IntermediateFieldDefinition(nameof(WixBundlePayloadTupleFields.Name), IntermediateFieldType.String), |
| 15 | new IntermediateFieldDefinition(nameof(WixBundlePayloadTupleFields.SourceFile), IntermediateFieldType.Path), | 14 | new IntermediateFieldDefinition(nameof(WixBundlePayloadTupleFields.SourceFile), IntermediateFieldType.Path), |
| 16 | new IntermediateFieldDefinition(nameof(WixBundlePayloadTupleFields.DownloadUrl), IntermediateFieldType.String), | 15 | new IntermediateFieldDefinition(nameof(WixBundlePayloadTupleFields.DownloadUrl), IntermediateFieldType.String), |
| @@ -26,10 +25,10 @@ namespace WixToolset.Data | |||
| 26 | new IntermediateFieldDefinition(nameof(WixBundlePayloadTupleFields.Thumbprint), IntermediateFieldType.String), | 25 | new IntermediateFieldDefinition(nameof(WixBundlePayloadTupleFields.Thumbprint), IntermediateFieldType.String), |
| 27 | new IntermediateFieldDefinition(nameof(WixBundlePayloadTupleFields.CatalogRef), IntermediateFieldType.String), | 26 | new IntermediateFieldDefinition(nameof(WixBundlePayloadTupleFields.CatalogRef), IntermediateFieldType.String), |
| 28 | new IntermediateFieldDefinition(nameof(WixBundlePayloadTupleFields.ContainerRef), IntermediateFieldType.String), | 27 | new IntermediateFieldDefinition(nameof(WixBundlePayloadTupleFields.ContainerRef), IntermediateFieldType.String), |
| 29 | new IntermediateFieldDefinition(nameof(WixBundlePayloadTupleFields.Package), IntermediateFieldType.String), | 28 | new IntermediateFieldDefinition(nameof(WixBundlePayloadTupleFields.PackageRef), IntermediateFieldType.String), |
| 30 | new IntermediateFieldDefinition(nameof(WixBundlePayloadTupleFields.ContentFile), IntermediateFieldType.Bool), | 29 | new IntermediateFieldDefinition(nameof(WixBundlePayloadTupleFields.ContentFile), IntermediateFieldType.Bool), |
| 31 | new IntermediateFieldDefinition(nameof(WixBundlePayloadTupleFields.EmbeddedId), IntermediateFieldType.String), | 30 | new IntermediateFieldDefinition(nameof(WixBundlePayloadTupleFields.EmbeddedId), IntermediateFieldType.String), |
| 32 | new IntermediateFieldDefinition(nameof(WixBundlePayloadTupleFields.LayoutOnly), IntermediateFieldType.Number), | 31 | new IntermediateFieldDefinition(nameof(WixBundlePayloadTupleFields.LayoutOnly), IntermediateFieldType.Bool), |
| 33 | new IntermediateFieldDefinition(nameof(WixBundlePayloadTupleFields.Packaging), IntermediateFieldType.Number), | 32 | new IntermediateFieldDefinition(nameof(WixBundlePayloadTupleFields.Packaging), IntermediateFieldType.Number), |
| 34 | new IntermediateFieldDefinition(nameof(WixBundlePayloadTupleFields.ParentPackagePayloadRef), IntermediateFieldType.String), | 33 | new IntermediateFieldDefinition(nameof(WixBundlePayloadTupleFields.ParentPackagePayloadRef), IntermediateFieldType.String), |
| 35 | }, | 34 | }, |
| @@ -43,7 +42,6 @@ namespace WixToolset.Data.Tuples | |||
| 43 | 42 | ||
| 44 | public enum WixBundlePayloadTupleFields | 43 | public enum WixBundlePayloadTupleFields |
| 45 | { | 44 | { |
| 46 | WixBundlePayload, | ||
| 47 | Name, | 45 | Name, |
| 48 | SourceFile, | 46 | SourceFile, |
| 49 | DownloadUrl, | 47 | DownloadUrl, |
| @@ -59,7 +57,7 @@ namespace WixToolset.Data.Tuples | |||
| 59 | Thumbprint, | 57 | Thumbprint, |
| 60 | CatalogRef, | 58 | CatalogRef, |
| 61 | ContainerRef, | 59 | ContainerRef, |
| 62 | Package, | 60 | PackageRef, |
| 63 | ContentFile, | 61 | ContentFile, |
| 64 | EmbeddedId, | 62 | EmbeddedId, |
| 65 | LayoutOnly, | 63 | LayoutOnly, |
| @@ -79,21 +77,15 @@ namespace WixToolset.Data.Tuples | |||
| 79 | 77 | ||
| 80 | public IntermediateField this[WixBundlePayloadTupleFields index] => this.Fields[(int)index]; | 78 | public IntermediateField this[WixBundlePayloadTupleFields index] => this.Fields[(int)index]; |
| 81 | 79 | ||
| 82 | public string WixBundlePayload | ||
| 83 | { | ||
| 84 | get => (string)this.Fields[(int)WixBundlePayloadTupleFields.WixBundlePayload]; | ||
| 85 | set => this.Set((int)WixBundlePayloadTupleFields.WixBundlePayload, value); | ||
| 86 | } | ||
| 87 | |||
| 88 | public string Name | 80 | public string Name |
| 89 | { | 81 | { |
| 90 | get => (string)this.Fields[(int)WixBundlePayloadTupleFields.Name]; | 82 | get => (string)this.Fields[(int)WixBundlePayloadTupleFields.Name]; |
| 91 | set => this.Set((int)WixBundlePayloadTupleFields.Name, value); | 83 | set => this.Set((int)WixBundlePayloadTupleFields.Name, value); |
| 92 | } | 84 | } |
| 93 | 85 | ||
| 94 | public string SourceFile | 86 | public IntermediateFieldPathValue SourceFile |
| 95 | { | 87 | { |
| 96 | get => (string)this.Fields[(int)WixBundlePayloadTupleFields.SourceFile]; | 88 | get => this.Fields[(int)WixBundlePayloadTupleFields.SourceFile].AsPath(); |
| 97 | set => this.Set((int)WixBundlePayloadTupleFields.SourceFile, value); | 89 | set => this.Set((int)WixBundlePayloadTupleFields.SourceFile, value); |
| 98 | } | 90 | } |
| 99 | 91 | ||
| @@ -103,10 +95,10 @@ namespace WixToolset.Data.Tuples | |||
| 103 | set => this.Set((int)WixBundlePayloadTupleFields.DownloadUrl, value); | 95 | set => this.Set((int)WixBundlePayloadTupleFields.DownloadUrl, value); |
| 104 | } | 96 | } |
| 105 | 97 | ||
| 106 | public YesNoDefaultType Compressed | 98 | public bool? Compressed |
| 107 | { | 99 | { |
| 108 | get => Enum.TryParse((string)this.Fields[(int)WixBundlePayloadTupleFields.Compressed], true, out YesNoDefaultType value) ? value : YesNoDefaultType.NotSet; | 100 | get => (bool?)this.Fields[(int)WixBundlePayloadTupleFields.Compressed]; |
| 109 | set => this.Set((int)WixBundlePayloadTupleFields.Compressed, value.ToString().ToLowerInvariant()); | 101 | set => this.Set((int)WixBundlePayloadTupleFields.Compressed, value); |
| 110 | } | 102 | } |
| 111 | 103 | ||
| 112 | public string UnresolvedSourceFile | 104 | public string UnresolvedSourceFile |
| @@ -175,10 +167,10 @@ namespace WixToolset.Data.Tuples | |||
| 175 | set => this.Set((int)WixBundlePayloadTupleFields.ContainerRef, value); | 167 | set => this.Set((int)WixBundlePayloadTupleFields.ContainerRef, value); |
| 176 | } | 168 | } |
| 177 | 169 | ||
| 178 | public string Package | 170 | public string PackageRef |
| 179 | { | 171 | { |
| 180 | get => (string)this.Fields[(int)WixBundlePayloadTupleFields.Package]; | 172 | get => (string)this.Fields[(int)WixBundlePayloadTupleFields.PackageRef]; |
| 181 | set => this.Set((int)WixBundlePayloadTupleFields.Package, value); | 173 | set => this.Set((int)WixBundlePayloadTupleFields.PackageRef, value); |
| 182 | } | 174 | } |
| 183 | 175 | ||
| 184 | public bool ContentFile | 176 | public bool ContentFile |
| @@ -193,16 +185,16 @@ namespace WixToolset.Data.Tuples | |||
| 193 | set => this.Set((int)WixBundlePayloadTupleFields.EmbeddedId, value); | 185 | set => this.Set((int)WixBundlePayloadTupleFields.EmbeddedId, value); |
| 194 | } | 186 | } |
| 195 | 187 | ||
| 196 | public int LayoutOnly | 188 | public bool LayoutOnly |
| 197 | { | 189 | { |
| 198 | get => (int)this.Fields[(int)WixBundlePayloadTupleFields.LayoutOnly]; | 190 | get => (bool)this.Fields[(int)WixBundlePayloadTupleFields.LayoutOnly]; |
| 199 | set => this.Set((int)WixBundlePayloadTupleFields.LayoutOnly, value); | 191 | set => this.Set((int)WixBundlePayloadTupleFields.LayoutOnly, value); |
| 200 | } | 192 | } |
| 201 | 193 | ||
| 202 | public int Packaging | 194 | public PackagingType Packaging |
| 203 | { | 195 | { |
| 204 | get => (int)this.Fields[(int)WixBundlePayloadTupleFields.Packaging]; | 196 | get => (PackagingType)this.Fields[(int)WixBundlePayloadTupleFields.Packaging].AsNumber(); |
| 205 | set => this.Set((int)WixBundlePayloadTupleFields.Packaging, value); | 197 | set => this.Set((int)WixBundlePayloadTupleFields.Packaging, (int)value); |
| 206 | } | 198 | } |
| 207 | 199 | ||
| 208 | public string ParentPackagePayloadRef | 200 | public string ParentPackagePayloadRef |
| @@ -211,4 +203,4 @@ namespace WixToolset.Data.Tuples | |||
| 211 | set => this.Set((int)WixBundlePayloadTupleFields.ParentPackagePayloadRef, value); | 203 | set => this.Set((int)WixBundlePayloadTupleFields.ParentPackagePayloadRef, value); |
| 212 | } | 204 | } |
| 213 | } | 205 | } |
| 214 | } \ No newline at end of file | 206 | } |
