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

  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. using System;
  16. using System.Reflection;
  17. namespace System.Reflection
  18. {
  19.     [AttributeUsage(AttributeTargets.Assembly | AttributeTargets.Class | AttributeTargets.Struct | AttributeTargets.Method | AttributeTargets.Parameter | AttributeTargets.Field | AttributeTargets.Property | AttributeTargets.Event | AttributeTargets.Interface | AttributeTargets.Enum | AttributeTargets.Delegate, AllowMultiple = true, Inherited = false)]
  20.     [System.Runtime.InteropServices.ComVisible(true)]
  21.     public sealed class ObfuscationAttribute : Attribute
  22.     {
  23.         private bool m_strip = true;
  24.         private bool m_exclude = true;
  25.         private bool m_applyToMembers = true;
  26.         private string m_feature = "all";
  27.        
  28.         public ObfuscationAttribute()
  29.         {
  30.         }
  31.        
  32.         public bool StripAfterObfuscation {
  33.             get { return m_strip; }
  34.             set { m_strip = value; }
  35.         }
  36.        
  37.         public bool Exclude {
  38.             get { return m_exclude; }
  39.             set { m_exclude = value; }
  40.         }
  41.        
  42.         public bool ApplyToMembers {
  43.             get { return m_applyToMembers; }
  44.             set { m_applyToMembers = value; }
  45.         }
  46.        
  47.         public string Feature {
  48.             get { return m_feature; }
  49.             set { m_feature = value; }
  50.         }
  51.     }
  52. }

Developer Fusion