/Mono.Cecil/Mono.Cecil/TypeAttributes.cs

http://github.com/icsharpcode/ILSpy · C# · 81 lines · 36 code · 10 blank · 35 comment · 0 complexity · 214defd9f893d218828261ec4b7dcfaa MD5 · raw file

  1. //
  2. // TypeAttributes.cs
  3. //
  4. // Author:
  5. // Jb Evain (jbevain@gmail.com)
  6. //
  7. // Copyright (c) 2008 - 2011 Jb Evain
  8. //
  9. // Permission is hereby granted, free of charge, to any person obtaining
  10. // a copy of this software and associated documentation files (the
  11. // "Software"), to deal in the Software without restriction, including
  12. // without limitation the rights to use, copy, modify, merge, publish,
  13. // distribute, sublicense, and/or sell copies of the Software, and to
  14. // permit persons to whom the Software is furnished to do so, subject to
  15. // the following conditions:
  16. //
  17. // The above copyright notice and this permission notice shall be
  18. // included in all copies or substantial portions of the Software.
  19. //
  20. // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
  21. // EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
  22. // MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
  23. // NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
  24. // LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
  25. // OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
  26. // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  27. //
  28. using System;
  29. namespace Mono.Cecil {
  30. [Flags]
  31. public enum TypeAttributes : uint {
  32. // Visibility attributes
  33. VisibilityMask = 0x00000007, // Use this mask to retrieve visibility information
  34. NotPublic = 0x00000000, // Class has no public scope
  35. Public = 0x00000001, // Class has public scope
  36. NestedPublic = 0x00000002, // Class is nested with public visibility
  37. NestedPrivate = 0x00000003, // Class is nested with private visibility
  38. NestedFamily = 0x00000004, // Class is nested with family visibility
  39. NestedAssembly = 0x00000005, // Class is nested with assembly visibility
  40. NestedFamANDAssem = 0x00000006, // Class is nested with family and assembly visibility
  41. NestedFamORAssem = 0x00000007, // Class is nested with family or assembly visibility
  42. // Class layout attributes
  43. LayoutMask = 0x00000018, // Use this mask to retrieve class layout information
  44. AutoLayout = 0x00000000, // Class fields are auto-laid out
  45. SequentialLayout = 0x00000008, // Class fields are laid out sequentially
  46. ExplicitLayout = 0x00000010, // Layout is supplied explicitly
  47. // Class semantics attributes
  48. ClassSemanticMask = 0x00000020, // Use this mask to retrieve class semantics information
  49. Class = 0x00000000, // Type is a class
  50. Interface = 0x00000020, // Type is an interface
  51. // Special semantics in addition to class semantics
  52. Abstract = 0x00000080, // Class is abstract
  53. Sealed = 0x00000100, // Class cannot be extended
  54. SpecialName = 0x00000400, // Class name is special
  55. // Implementation attributes
  56. Import = 0x00001000, // Class/Interface is imported
  57. Serializable = 0x00002000, // Class is serializable
  58. WindowsRuntime = 0x00004000, // Windows Runtime type
  59. // String formatting attributes
  60. StringFormatMask = 0x00030000, // Use this mask to retrieve string information for native interop
  61. AnsiClass = 0x00000000, // LPSTR is interpreted as ANSI
  62. UnicodeClass = 0x00010000, // LPSTR is interpreted as Unicode
  63. AutoClass = 0x00020000, // LPSTR is interpreted automatically
  64. // Class initialization attributes
  65. BeforeFieldInit = 0x00100000, // Initialize the class before first static field access
  66. // Additional flags
  67. RTSpecialName = 0x00000800, // CLI provides 'special' behavior, depending upon the name of the Type
  68. HasSecurity = 0x00040000, // Type has security associate with it
  69. Forwarder = 0x00200000, // Exported type is a type forwarder
  70. }
  71. }