summaryrefslogtreecommitdiff
path: root/src/ext/Util/wixext/Symbols/FileShareSymbol.cs
diff options
context:
space:
mode:
Diffstat (limited to 'src/ext/Util/wixext/Symbols/FileShareSymbol.cs')
-rw-r--r--src/ext/Util/wixext/Symbols/FileShareSymbol.cs71
1 files changed, 71 insertions, 0 deletions
diff --git a/src/ext/Util/wixext/Symbols/FileShareSymbol.cs b/src/ext/Util/wixext/Symbols/FileShareSymbol.cs
new file mode 100644
index 00000000..c956ff42
--- /dev/null
+++ b/src/ext/Util/wixext/Symbols/FileShareSymbol.cs
@@ -0,0 +1,71 @@
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.Util
4{
5 using WixToolset.Data;
6 using WixToolset.Util.Symbols;
7
8 public static partial class UtilSymbolDefinitions
9 {
10 public static readonly IntermediateSymbolDefinition FileShare = new IntermediateSymbolDefinition(
11 UtilSymbolDefinitionType.FileShare.ToString(),
12 new[]
13 {
14 new IntermediateFieldDefinition(nameof(FileShareSymbolFields.ShareName), IntermediateFieldType.String),
15 new IntermediateFieldDefinition(nameof(FileShareSymbolFields.ComponentRef), IntermediateFieldType.String),
16 new IntermediateFieldDefinition(nameof(FileShareSymbolFields.Description), IntermediateFieldType.String),
17 new IntermediateFieldDefinition(nameof(FileShareSymbolFields.DirectoryRef), IntermediateFieldType.String),
18 },
19 typeof(FileShareSymbol));
20 }
21}
22
23namespace WixToolset.Util.Symbols
24{
25 using WixToolset.Data;
26
27 public enum FileShareSymbolFields
28 {
29 ShareName,
30 ComponentRef,
31 Description,
32 DirectoryRef,
33 }
34
35 public class FileShareSymbol : IntermediateSymbol
36 {
37 public FileShareSymbol() : base(UtilSymbolDefinitions.FileShare, null, null)
38 {
39 }
40
41 public FileShareSymbol(SourceLineNumber sourceLineNumber, Identifier id = null) : base(UtilSymbolDefinitions.FileShare, sourceLineNumber, id)
42 {
43 }
44
45 public IntermediateField this[FileShareSymbolFields index] => this.Fields[(int)index];
46
47 public string ShareName
48 {
49 get => this.Fields[(int)FileShareSymbolFields.ShareName].AsString();
50 set => this.Set((int)FileShareSymbolFields.ShareName, value);
51 }
52
53 public string ComponentRef
54 {
55 get => this.Fields[(int)FileShareSymbolFields.ComponentRef].AsString();
56 set => this.Set((int)FileShareSymbolFields.ComponentRef, value);
57 }
58
59 public string Description
60 {
61 get => this.Fields[(int)FileShareSymbolFields.Description].AsString();
62 set => this.Set((int)FileShareSymbolFields.Description, value);
63 }
64
65 public string DirectoryRef
66 {
67 get => this.Fields[(int)FileShareSymbolFields.DirectoryRef].AsString();
68 set => this.Set((int)FileShareSymbolFields.DirectoryRef, value);
69 }
70 }
71} \ No newline at end of file