aboutsummaryrefslogtreecommitdiff
path: root/src/wixext/PSExtensionData.cs
diff options
context:
space:
mode:
Diffstat (limited to 'src/wixext/PSExtensionData.cs')
-rw-r--r--src/wixext/PSExtensionData.cs26
1 files changed, 11 insertions, 15 deletions
diff --git a/src/wixext/PSExtensionData.cs b/src/wixext/PSExtensionData.cs
index 578bda91..d9a2d2e7 100644
--- a/src/wixext/PSExtensionData.cs
+++ b/src/wixext/PSExtensionData.cs
@@ -1,34 +1,30 @@
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. 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 2
3namespace WixToolset.Extensions 3namespace WixToolset.PowerShell
4{ 4{
5 using System;
6 using System.Reflection;
7 using WixToolset.Data; 5 using WixToolset.Data;
8 using WixToolset.Extensibility; 6 using WixToolset.Extensibility;
9 7
10 /// <summary> 8 /// <summary>
11 /// The WiX Toolset PowerShell Extension. 9 /// The WiX Toolset PowerShell Extension.
12 /// </summary> 10 /// </summary>
13 public sealed class PSExtensionData : ExtensionData 11 public sealed class PSExtensionData : BaseExtensionData
14 { 12 {
15 /// <summary> 13 /// <summary>
16 /// Gets the library associated with this extension. 14 /// Gets the default culture.
17 /// </summary> 15 /// </summary>
18 /// <param name="tableDefinitions">The table definitions to use while loading the library.</param> 16 /// <value>The default culture.</value>
19 /// <returns>The loaded library.</returns> 17 public override string DefaultCulture => "en-US";
20 public override Library GetLibrary(TableDefinitionCollection tableDefinitions) 18
19 public override bool TryGetTupleDefinitionByName(string name, out IntermediateTupleDefinition tupleDefinition)
21 { 20 {
22 return PSExtensionData.GetExtensionLibrary(tableDefinitions); 21 tupleDefinition = null;
22 return tupleDefinition != null;
23 } 23 }
24 24
25 /// <summary> 25 public override Intermediate GetLibrary(ITupleDefinitionCreator tupleDefinitions)
26 /// Internal mechanism to access the extension's library.
27 /// </summary>
28 /// <returns>Extension's library.</returns>
29 internal static Library GetExtensionLibrary(TableDefinitionCollection tableDefinitions)
30 { 26 {
31 return ExtensionData.LoadLibraryHelper(Assembly.GetExecutingAssembly(), "WixToolset.Extensions.Data.ps.wixlib", tableDefinitions); 27 return Intermediate.Load(typeof(PSExtensionData).Assembly, "WixToolset.PowerShell.powershell.wixlib", tupleDefinitions);
32 } 28 }
33 } 29 }
34} 30}