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

  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.Runtime.Remoting;
  17. using System.Runtime.Serialization;
  18. using System.Security.Permissions;
  19. namespace System.Reflection
  20. {
  21.     // This is not serializable because it is a reflection command.
  22.     [Serializable()]
  23.     [System.Runtime.InteropServices.ComVisible(true)]
  24.     public sealed class Missing : ISerializable
  25.     {
  26.         public static readonly Missing Value = new Missing();
  27.        
  28.         #region Constructor
  29.         private Missing()
  30.         {
  31.         }
  32.         #endregion
  33.        
  34.         #region ISerializable
  35.         [SecurityPermissionAttribute(SecurityAction.LinkDemand, Flags = SecurityPermissionFlag.SerializationFormatter)]
  36.         void ISerializable.GetObjectData(SerializationInfo info, StreamingContext context)
  37.         {
  38.             if (info == null)
  39.                 throw new ArgumentNullException("info");
  40.            
  41.             UnitySerializationHolder.GetUnitySerializationInfo(info, this);
  42.         }
  43.         #endregion
  44.     }
  45. }

Developer Fusion