aboutsummaryrefslogtreecommitdiff
path: root/src/WixToolset.Data.WindowsInstaller/Rows/WixPropertyRow.cs
diff options
context:
space:
mode:
Diffstat (limited to 'src/WixToolset.Data.WindowsInstaller/Rows/WixPropertyRow.cs')
-rw-r--r--src/WixToolset.Data.WindowsInstaller/Rows/WixPropertyRow.cs118
1 files changed, 0 insertions, 118 deletions
diff --git a/src/WixToolset.Data.WindowsInstaller/Rows/WixPropertyRow.cs b/src/WixToolset.Data.WindowsInstaller/Rows/WixPropertyRow.cs
deleted file mode 100644
index 5285195c..00000000
--- a/src/WixToolset.Data.WindowsInstaller/Rows/WixPropertyRow.cs
+++ /dev/null
@@ -1,118 +0,0 @@
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
3namespace WixToolset.Data.Rows
4{
5 using System;
6 using System.Globalization;
7
8 /// <summary>
9 /// Specialization of a row for the WixProperty table.
10 /// </summary>
11 public sealed class WixPropertyRow : Row
12 {
13 /// <summary>Creates a WixProperty row that belongs to a table.</summary>
14 /// <param name="sourceLineNumbers">Original source lines for this row.</param>
15 /// <param name="table">Table this WixProperty row belongs to and should get its column definitions from.</param>
16 public WixPropertyRow(SourceLineNumber sourceLineNumbers, Table table) :
17 base(sourceLineNumbers, table)
18 {
19 }
20
21 /// <summary>
22 /// Gets and sets the id for this property row.
23 /// </summary>
24 /// <value>Id for the property.</value>
25 public string Id
26 {
27 get { return (string)this.Fields[0].Data; }
28 set { this.Fields[0].Data = value; }
29 }
30
31 /// <summary>
32 /// Gets and sets if this is an admin property row.
33 /// </summary>
34 /// <value>Flag if this is an admin property.</value>
35 public bool Admin
36 {
37 get
38 {
39 return (0x1 == (Convert.ToInt32(this.Fields[1].Data, CultureInfo.InvariantCulture) & 0x1));
40 }
41
42 set
43 {
44 if (null == this.Fields[1].Data)
45 {
46 this.Fields[1].Data = 0;
47 }
48
49 if (value)
50 {
51 this.Fields[1].Data = (int)this.Fields[1].Data | 0x1;
52 }
53 else
54 {
55 this.Fields[1].Data = (int)this.Fields[1].Data & ~0x1;
56 }
57 }
58 }
59
60 /// <summary>
61 /// Gets and sets if this is a hidden property row.
62 /// </summary>
63 /// <value>Flag if this is a hidden property.</value>
64 public bool Hidden
65 {
66 get
67 {
68 return (0x2 == (Convert.ToInt32(this.Fields[1].Data, CultureInfo.InvariantCulture) & 0x2));
69 }
70
71 set
72 {
73 if (null == this.Fields[1].Data)
74 {
75 this.Fields[1].Data = 0;
76 }
77
78 if (value)
79 {
80 this.Fields[1].Data = (int)this.Fields[1].Data | 0x2;
81 }
82 else
83 {
84 this.Fields[1].Data = (int)this.Fields[1].Data & ~0x2;
85 }
86 }
87 }
88
89 /// <summary>
90 /// Gets and sets if this is a secure property row.
91 /// </summary>
92 /// <value>Flag if this is a secure property.</value>
93 public bool Secure
94 {
95 get
96 {
97 return (0x4 == (Convert.ToInt32(this.Fields[1].Data, CultureInfo.InvariantCulture) & 0x4));
98 }
99
100 set
101 {
102 if (null == this.Fields[1].Data)
103 {
104 this.Fields[1].Data = 0;
105 }
106
107 if (value)
108 {
109 this.Fields[1].Data = (int)this.Fields[1].Data | 0x4;
110 }
111 else
112 {
113 this.Fields[1].Data = (int)this.Fields[1].Data & ~0x4;
114 }
115 }
116 }
117 }
118}