The Labs \ Source Viewer \ SSCLI \ System.Reflection \ FieldAttributes

  1. // ==++==
  2. //
  3. //
  4. // Copyright (c) 2006 Microsoft Corporation. All rights reserved.
  5. //
  6. // The use and distribution terms for this software are contained in the file
  7. // named license.txt, which can be found in the root of this distribution.
  8. // By using this software in any fashion, you are agreeing to be bound by the
  9. // terms of this license.
  10. //
  11. // You must not remove this notice, or any other, from this software.
  12. //
  13. //
  14. // ==--==
  15. namespace System.Reflection
  16. {
  17.    
  18.     using System;
  19.     // This Enum matchs the CorFieldAttr defined in CorHdr.h
  20.     [Serializable()]
  21.     [Flags()]
  22.     [System.Runtime.InteropServices.ComVisible(true)]
  23.     public enum FieldAttributes
  24.     {
  25.         // member access mask - Use this mask to retrieve accessibility information.
  26.         FieldAccessMask = 7,
  27.         PrivateScope = 0,
  28.         // Member not referenceable.
  29.         Private = 1,
  30.         // Accessible only by the parent type.
  31.         FamANDAssem = 2,
  32.         // Accessible by sub-types only in this Assembly.
  33.         Assembly = 3,
  34.         // Accessibly by anyone in the Assembly.
  35.         Family = 4,
  36.         // Accessible only by type and sub-types.
  37.         FamORAssem = 5,
  38.         // Accessibly by sub-types anywhere, plus anyone in assembly.
  39.         Public = 6,
  40.         // Accessibly by anyone who has visibility to this scope.
  41.         // end member access mask
  42.         // field contract attributes.
  43.         Static = 16,
  44.         // Defined on type, else per instance.
  45.         InitOnly = 32,
  46.         // Field may only be initialized, not written to after init.
  47.         Literal = 64,
  48.         // Value is compile time constant.
  49.         NotSerialized = 128,
  50.         // Field does not have to be serialized when type is remoted.
  51.         SpecialName = 512,
  52.         // field is special. Name describes how.
  53.         // interop attributes
  54.         PinvokeImpl = 8192,
  55.         // Implementation is forwarded through pinvoke.
  56.         // Reserved flags for runtime use only.
  57.         ReservedMask = 38144,
  58.         RTSpecialName = 1024,
  59.         // Runtime(metadata internal APIs) should check name encoding.
  60.         HasFieldMarshal = 4096,
  61.         // Field has marshalling information.
  62.         HasDefault = 32768,
  63.         // Field has default.
  64.         HasFieldRVA = 256
  65.         // Field has RVA.
  66.     }
  67. }

Developer Fusion