1 // Licensed to the .NET Foundation under one or more agreements. 2 // The .NET Foundation licenses this file to you under the MIT license. 3 // See the LICENSE file in the project root for more information. 4 5 namespace System.Runtime.InteropServices 6 { 7 [AttributeUsage(AttributeTargets.Method, Inherited = false)] 8 public sealed class DllImportAttribute : Attribute 9 { DllImportAttribute(string dllName)10 public DllImportAttribute(string dllName) 11 { 12 Value = dllName; 13 } 14 15 public string Value { get; } 16 17 public string EntryPoint; 18 public CharSet CharSet; 19 public bool SetLastError; 20 public bool ExactSpelling; 21 public CallingConvention CallingConvention; 22 public bool BestFitMapping; 23 public bool PreserveSig; 24 public bool ThrowOnUnmappableChar; 25 } 26 } 27