diff options
Diffstat (limited to 'src/api')
-rw-r--r-- | src/api/wix/WixToolset.Extensibility/Data/IExtensionCacheLocation.cs | 41 | ||||
-rw-r--r-- | src/api/wix/WixToolset.Extensibility/Services/IExtensionManager.cs | 7 |
2 files changed, 48 insertions, 0 deletions
diff --git a/src/api/wix/WixToolset.Extensibility/Data/IExtensionCacheLocation.cs b/src/api/wix/WixToolset.Extensibility/Data/IExtensionCacheLocation.cs new file mode 100644 index 00000000..53158875 --- /dev/null +++ b/src/api/wix/WixToolset.Extensibility/Data/IExtensionCacheLocation.cs | |||
@@ -0,0 +1,41 @@ | |||
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.Extensibility.Data | ||
4 | { | ||
5 | /// <summary> | ||
6 | /// Extension cache location scope. | ||
7 | /// </summary> | ||
8 | public enum ExtensionCacheLocationScope | ||
9 | { | ||
10 | /// <summary> | ||
11 | /// Project extension cache location. | ||
12 | /// </summary> | ||
13 | Project, | ||
14 | |||
15 | /// <summary> | ||
16 | /// User extension cache location. | ||
17 | /// </summary> | ||
18 | User, | ||
19 | |||
20 | /// <summary> | ||
21 | /// Machine extension cache location. | ||
22 | /// </summary> | ||
23 | Machine, | ||
24 | } | ||
25 | |||
26 | /// <summary> | ||
27 | /// Location where extensions may be cached. | ||
28 | /// </summary> | ||
29 | public interface IExtensionCacheLocation | ||
30 | { | ||
31 | /// <summary> | ||
32 | /// Path for the extension cache location. | ||
33 | /// </summary> | ||
34 | string Path { get; } | ||
35 | |||
36 | /// <summary> | ||
37 | /// Scope for the extension cache location. | ||
38 | /// </summary> | ||
39 | ExtensionCacheLocationScope Scope { get; } | ||
40 | } | ||
41 | } | ||
diff --git a/src/api/wix/WixToolset.Extensibility/Services/IExtensionManager.cs b/src/api/wix/WixToolset.Extensibility/Services/IExtensionManager.cs index 8e49c38d..fe939a59 100644 --- a/src/api/wix/WixToolset.Extensibility/Services/IExtensionManager.cs +++ b/src/api/wix/WixToolset.Extensibility/Services/IExtensionManager.cs | |||
@@ -4,6 +4,7 @@ namespace WixToolset.Extensibility.Services | |||
4 | { | 4 | { |
5 | using System.Collections.Generic; | 5 | using System.Collections.Generic; |
6 | using System.Reflection; | 6 | using System.Reflection; |
7 | using WixToolset.Extensibility.Data; | ||
7 | 8 | ||
8 | /// <summary> | 9 | /// <summary> |
9 | /// Loads extensions and uses the extensions' factories to provide services. | 10 | /// Loads extensions and uses the extensions' factories to provide services. |
@@ -33,6 +34,12 @@ namespace WixToolset.Extensibility.Services | |||
33 | void Load(string extensionReference); | 34 | void Load(string extensionReference); |
34 | 35 | ||
35 | /// <summary> | 36 | /// <summary> |
37 | /// Gets extensions cache locations. | ||
38 | /// </summary> | ||
39 | /// <returns>List of cache locations where extensions may be found.</returns> | ||
40 | IReadOnlyCollection<IExtensionCacheLocation> GetCacheLocations(); | ||
41 | |||
42 | /// <summary> | ||
36 | /// Gets extensions of specified type from factories loaded into the extension manager. | 43 | /// Gets extensions of specified type from factories loaded into the extension manager. |
37 | /// </summary> | 44 | /// </summary> |
38 | /// <typeparam name="T">Type of extension to get.</typeparam> | 45 | /// <typeparam name="T">Type of extension to get.</typeparam> |