summaryrefslogtreecommitdiff
path: root/src/api/burn/WixToolset.Mba.Core/NativeMethods.cs
diff options
context:
space:
mode:
authorRob Mensching <rob@firegiant.com>2021-04-22 05:46:03 -0700
committerRob Mensching <rob@firegiant.com>2021-04-29 16:41:44 -0700
commitc00516901e6b67e398396b14fe7682d0376f8643 (patch)
treeb0d62089a1c5700c7f2c3e3790750bf2d8ea33c0 /src/api/burn/WixToolset.Mba.Core/NativeMethods.cs
parent8eb98efd2175d9ece2e4639d43081667af9a4990 (diff)
downloadwix-c00516901e6b67e398396b14fe7682d0376f8643.tar.gz
wix-c00516901e6b67e398396b14fe7682d0376f8643.tar.bz2
wix-c00516901e6b67e398396b14fe7682d0376f8643.zip
Move balutil into API/burn
Diffstat (limited to 'src/api/burn/WixToolset.Mba.Core/NativeMethods.cs')
-rw-r--r--src/api/burn/WixToolset.Mba.Core/NativeMethods.cs37
1 files changed, 37 insertions, 0 deletions
diff --git a/src/api/burn/WixToolset.Mba.Core/NativeMethods.cs b/src/api/burn/WixToolset.Mba.Core/NativeMethods.cs
new file mode 100644
index 00000000..adb2256e
--- /dev/null
+++ b/src/api/burn/WixToolset.Mba.Core/NativeMethods.cs
@@ -0,0 +1,37 @@
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.Mba.Core
4{
5 using System;
6 using System.Runtime.InteropServices;
7
8 /// <summary>
9 /// Contains native constants, functions, and structures for this assembly.
10 /// </summary>
11 internal static class NativeMethods
12 {
13 #region Error Constants
14 internal const int S_OK = 0;
15 internal const int E_MOREDATA = unchecked((int)0x800700ea);
16 internal const int E_INSUFFICIENT_BUFFER = unchecked((int)0x8007007a);
17 internal const int E_CANCELLED = unchecked((int)0x800704c7);
18 internal const int E_ALREADYINITIALIZED = unchecked((int)0x800704df);
19 internal const int E_NOTFOUND = unchecked((int)0x80070490);
20 internal const int E_NOTIMPL = unchecked((int)0x80004001);
21 internal const int E_UNEXPECTED = unchecked((int)0x8000ffff);
22 #endregion
23
24 #region Functions
25 [DllImport("shell32.dll", ExactSpelling = true, SetLastError = true)]
26 internal static extern IntPtr CommandLineToArgvW(
27 [MarshalAs(UnmanagedType.LPWStr)] string lpCmdLine,
28 out int pNumArgs
29 );
30
31 [DllImport("kernel32.dll", ExactSpelling = true, SetLastError = true)]
32 internal static extern IntPtr LocalFree(
33 IntPtr hMem
34 );
35 #endregion
36 }
37}