diff options
Diffstat (limited to 'src/WixToolset.Core/BinderFileManagerCore.cs')
-rw-r--r-- | src/WixToolset.Core/BinderFileManagerCore.cs | 102 |
1 files changed, 0 insertions, 102 deletions
diff --git a/src/WixToolset.Core/BinderFileManagerCore.cs b/src/WixToolset.Core/BinderFileManagerCore.cs deleted file mode 100644 index aa9a45de..00000000 --- a/src/WixToolset.Core/BinderFileManagerCore.cs +++ /dev/null | |||
@@ -1,102 +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 | |||
3 | namespace WixToolset | ||
4 | { | ||
5 | using System; | ||
6 | using System.Collections.Generic; | ||
7 | using System.Linq; | ||
8 | using WixToolset.Data; | ||
9 | using WixToolset.Data.Bind; | ||
10 | using WixToolset.Extensibility; | ||
11 | |||
12 | #if DEAD_CODE | ||
13 | public class BinderFileManagerCore : IBinderFileManagerCore | ||
14 | { | ||
15 | private Dictionary<string, List<string>>[] bindPaths; | ||
16 | |||
17 | /// <summary> | ||
18 | /// Instantiate a new BinderFileManager. | ||
19 | /// </summary> | ||
20 | public BinderFileManagerCore() | ||
21 | { | ||
22 | this.bindPaths = new Dictionary<string, List<string>>[3]; | ||
23 | this.bindPaths[(int)BindStage.Normal] = new Dictionary<string, List<string>>(); | ||
24 | this.bindPaths[(int)BindStage.Target] = new Dictionary<string, List<string>>(); | ||
25 | this.bindPaths[(int)BindStage.Updated] = new Dictionary<string, List<string>>(); | ||
26 | } | ||
27 | |||
28 | /// <summary> | ||
29 | /// Gets or sets the path to cabinet cache. | ||
30 | /// </summary> | ||
31 | /// <value>The path to cabinet cache.</value> | ||
32 | public string CabCachePath { get; set; } | ||
33 | |||
34 | /// <summary> | ||
35 | /// Gets or sets the active subStorage used for binding. | ||
36 | /// </summary> | ||
37 | /// <value>The subStorage object.</value> | ||
38 | //public SubStorage ActiveSubStorage { get; set; } | ||
39 | |||
40 | /// <summary> | ||
41 | /// Gets or sets the output object used for binding. | ||
42 | /// </summary> | ||
43 | /// <value>The output object.</value> | ||
44 | public Intermediate Intermediate { get; set; } | ||
45 | |||
46 | /// <summary> | ||
47 | /// Gets or sets the path to the temp files location. | ||
48 | /// </summary> | ||
49 | /// <value>The path to the temp files location.</value> | ||
50 | public string TempFilesLocation { get; set; } | ||
51 | |||
52 | /// <summary> | ||
53 | /// Gets the property if re-basing target is true or false | ||
54 | /// </summary> | ||
55 | /// <value>It returns true if target bind path is to be replaced, otherwise false.</value> | ||
56 | public bool RebaseTarget | ||
57 | { | ||
58 | get { return this.bindPaths[(int)BindStage.Target].Any(); } | ||
59 | } | ||
60 | |||
61 | /// <summary> | ||
62 | /// Gets the property if re-basing updated build is true or false | ||
63 | /// </summary> | ||
64 | /// <value>It returns true if updated bind path is to be replaced, otherwise false.</value> | ||
65 | public bool RebaseUpdated | ||
66 | { | ||
67 | get { return this.bindPaths[(int)BindStage.Updated].Any(); } | ||
68 | } | ||
69 | |||
70 | public void AddBindPaths(IEnumerable<BindPath> paths, BindStage stage) | ||
71 | { | ||
72 | Dictionary<string, List<string>> dict = this.bindPaths[(int)stage]; | ||
73 | |||
74 | foreach (BindPath bindPath in paths) | ||
75 | { | ||
76 | List<string> values; | ||
77 | if (!dict.TryGetValue(bindPath.Name, out values)) | ||
78 | { | ||
79 | values = new List<string>(); | ||
80 | dict.Add(bindPath.Name, values); | ||
81 | } | ||
82 | |||
83 | if (!values.Contains(bindPath.Path)) | ||
84 | { | ||
85 | values.Add(bindPath.Path); | ||
86 | } | ||
87 | } | ||
88 | } | ||
89 | |||
90 | public IEnumerable<string> GetBindPaths(BindStage stage = BindStage.Normal, string name = null) | ||
91 | { | ||
92 | List<string> paths; | ||
93 | if (this.bindPaths[(int)stage].TryGetValue(name ?? String.Empty, out paths)) | ||
94 | { | ||
95 | return paths; | ||
96 | } | ||
97 | |||
98 | return Enumerable.Empty<string>(); | ||
99 | } | ||
100 | } | ||
101 | #endif | ||
102 | } | ||