zoukankan      html  css  js  c++  java
  • Implement EventArgs

    #region *** CCSimpleEventArgs ***
    /// <summary>
    /// A generic class that implements the requisite constructor and property for a custom event args
    /// class with one data member.
    /// </summary>
    /// <typeparam name="T">Single data member for EventArgs</typeparam>
    [Serializable]
    [System.ComponentModel.ImmutableObject(true)]
    public class CCSimpleEventArgs<T> : EventArgs
    {
    /// <summary>Holder for single data member</summary>
    private readonly T argValue;

    /// <summary>Public accessor for single data member</summary>
    public T Value
    {
    get { return argValue; }
    }

    /// <summary>
    /// Constructor. Stores single data memeber.
    /// </summary>
    /// <param name="value">Single data member for EventArgs</param>
    public CCSimpleEventArgs(T value)
    {
    argValue = value;
    }
    }
    #endregion

  • 相关阅读:
    SpringBoot04-web
    springboot03-日志功能
    SpringBoot02-自动配置原理
    SpringBoot02
    SpringBoot01
    八大排序算法
    SpringSecurity04
    SpringSecurity03
    SpringSecurity02
    SpringSecurity01
  • 原文地址:https://www.cnblogs.com/zhangchenliang/p/2659328.html
Copyright © 2011-2022 走看看