The Labs \ Source Viewer \ SSCLI \ System.CodeDom \ CodeSnippetTypeMember

  1. //------------------------------------------------------------------------------
  2. // <copyright file="CodeSnippetTypeMember.cs" company="Microsoft">
  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. // </copyright>
  14. //------------------------------------------------------------------------------
  15. namespace System.CodeDom
  16. {
  17.    
  18.     using System.Diagnostics;
  19.     using System;
  20.     using Microsoft.Win32;
  21.     using System.Collections;
  22.     using System.Reflection;
  23.     using System.Runtime.InteropServices;
  24.    
  25.     /// <devdoc>
  26.     /// <para>
  27.     /// Represents a
  28.     /// snippet member of a class.
  29.     /// </para>
  30.     /// </devdoc>
  31.     [ClassInterface(ClassInterfaceType.AutoDispatch), ComVisible(true), Serializable()]
  32.     public class CodeSnippetTypeMember : CodeTypeMember
  33.     {
  34.         private string text;
  35.        
  36.         /// <devdoc>
  37.         /// <para>
  38.         /// Initializes a new instance of <see cref='System.CodeDom.CodeSnippetTypeMember'/>.
  39.         /// </para>
  40.         /// </devdoc>
  41.         public CodeSnippetTypeMember()
  42.         {
  43.         }
  44.        
  45.         /// <devdoc>
  46.         /// <para>
  47.         /// Initializes a new instance of <see cref='System.CodeDom.CodeSnippetTypeMember'/>.
  48.         /// </para>
  49.         /// </devdoc>
  50.         public CodeSnippetTypeMember(string text)
  51.         {
  52.             Text = text;
  53.         }
  54.        
  55.         /// <devdoc>
  56.         /// <para>
  57.         /// Gets or sets the code for the class member.
  58.         /// </para>
  59.         /// </devdoc>
  60.         public string Text {
  61.             get { return (text == null) ? string.Empty : text; }
  62.             set { text = value; }
  63.         }
  64.     }
  65. }

Developer Fusion