2 Copyright (C) 2009-2012 Jeroen Frijters
4 This software is provided 'as-is', without any express or implied
5 warranty. In no event will the authors be held liable for any damages
6 arising from the use of this software.
8 Permission is granted to anyone to use this software for any purpose,
9 including commercial applications, and to alter it and redistribute it
10 freely, subject to the following restrictions:
12 1. The origin of this software must not be misrepresented; you must not
13 claim that you wrote the original software. If you use this software
14 in a product, an acknowledgment in the product documentation would be
15 appreciated but is not required.
16 2. Altered source versions must be plainly marked as such, and must not be
17 misrepresented as being the original software.
18 3. This notice may not be removed or altered from any source distribution.
26 namespace IKVM.Reflection
29 public enum AssemblyNameFlags
34 EnableJITcompileOptimizer = 16384,
35 EnableJITcompileTracking = 32768,
38 public enum AssemblyContentType
45 public enum BindingFlags
54 FlattenHierarchy = 64,
58 public enum CallingConventions
68 public enum EventAttributes
77 public enum FieldAttributes
94 HasFieldMarshal = 4096,
101 public enum GenericParameterAttributes
107 ReferenceTypeConstraint = 4,
108 NotNullableValueTypeConstraint = 8,
109 DefaultConstructorConstraint = 16,
110 SpecialConstraintMask = 28,
113 public enum ImageFileMachine
122 public enum MemberTypes
132 All = Constructor | Event | Field | Method | Property | TypeInfo | NestedType
136 public enum MethodAttributes
138 MemberAccessMask = 0x0007,
139 PrivateScope = 0x0000,
141 FamANDAssem = 0x0002,
150 VtableLayoutMask = 0x0100,
153 CheckAccessOnOverride = 0x0200,
155 SpecialName = 0x0800,
157 PinvokeImpl = 0x2000,
158 UnmanagedExport = 0x0008,
160 RTSpecialName = 0x1000,
161 HasSecurity = 0x4000,
162 RequireSecObject = 0x8000,
164 ReservedMask = 0xd000,
168 public enum MethodImplAttributes
170 CodeTypeMask = 0x0003,
175 ManagedMask = 0x0004,
180 PreserveSig = 0x0080,
181 InternalCall = 0x1000,
182 Synchronized = 0x0020,
184 NoOptimization = 0x0040,
185 AggressiveInlining = 0x0100,
187 MaxMethodImplVal = 0xffff,
191 public enum ParameterAttributes
200 HasFieldMarshal = 8192,
203 ReservedMask = 61440,
207 public enum PortableExecutableKinds
209 NotAPortableExecutableImage = 0,
217 public enum ProcessorArchitecture
225 // if an item is added here, make sure to update AssemblyName.ProcessorArchitecture and Fusion.ParseAssemblyName as well
229 public enum PropertyAttributes
233 RTSpecialName = 1024,
238 public enum ResourceAttributes
245 public enum ResourceLocation
248 ContainedInAnotherAssembly = 2,
249 ContainedInManifestFile = 4,
253 public enum TypeAttributes
264 NestedFamANDAssem = 6,
266 NestedFamORAssem = 7,
267 SequentialLayout = 8,
270 ClassSemanticsMask = 32,
275 RTSpecialName = 2048,
278 WindowsRuntime = 16384,
279 UnicodeClass = 65536,
281 CustomFormatClass = 196608,
282 StringFormatMask = 196608,
283 HasSecurity = 262144,
284 ReservedMask = 264192,
285 BeforeFieldInit = 1048576,
286 CustomFormatMask = 12582912,
289 // IKVM.Reflection specific type
291 public enum DllCharacteristics
293 HighEntropyVA = 0x0020, // IMAGE_DLLCHARACTERISTICS_HIGH_ENTROPY_VA
294 DynamicBase = 0x0040, // IMAGE_DLLCHARACTERISTICS_DYNAMIC_BASE
295 NoSEH = 0x0400, // IMAGE_DLLCHARACTERISTICS_NO_SEH
296 NXCompat = 0x0100, // IMAGE_DLLCHARACTERISTICS_NX_COMPAT
297 AppContainer = 0x1000, // IMAGE_DLLCHARACTERISTICS_APPCONTAINER
298 TerminalServerAware = 0x8000, // IMAGE_DLLCHARACTERISTICS_TERMINAL_SERVER_AWARE
301 // IKVM.Reflection specific type
303 public enum ImplMapFlags
306 CharSetMask = 0x0006,
307 CharSetNotSpec = 0x0000,
308 CharSetAnsi = 0x0002,
309 CharSetUnicode = 0x0004,
310 CharSetAuto = 0x0006,
311 SupportsLastError = 0x0040,
312 CallConvMask = 0x0700,
313 CallConvWinapi = 0x0100,
314 CallConvCdecl = 0x0200,
315 CallConvStdcall = 0x0300,
316 CallConvThiscall = 0x0400,
317 CallConvFastcall = 0x0500,
318 // non-standard flags (i.e. CLR specific)
321 CharMapErrorOn = 0x1000,
322 CharMapErrorOff = 0x2000,