码迷,mamicode.com
首页 > 其他好文 > 详细

枚举类型-用法

时间:2016-10-27 10:25:30      阅读:221      评论:0      收藏:0      [点我收藏+]

标签:tar   单位   info   flags   object   field   企业   led   gif   

  /// <summary>
    /// 声明三方查询类型可以关联的查询对象类型
    /// </summary>
    [AttributeUsage(AttributeTargets.Field, Inherited = false, AllowMultiple = true)]
    public sealed class IncludeAttribute : Attribute
    {
        public ThirdInfoCategroyObjectType Detail { get; private set; }
        public IncludeAttribute(ThirdInfoCategroyObjectType detail)
        {
            this.Detail = detail;
        }
    }
技术分享
[Flags]
    public enum ThirdInfoCategroyObjectType
    {


        /// <summary>
        /// 申请人ID
        /// </summary>
        [Description("申请人ID")]
        ApplyID = 1,
        /// <summary>
        /// 配偶ID
        /// </summary>
        [Description("配偶ID")]
        SpouseID = 2,
        /// <summary>
        /// 企业名称
        /// </summary>
        [Description("企业名称")]
        EnterpriseName = 3,
        /// <summary>
        /// 企业地址
        /// </summary>
        [Description("企业地址")]
        EnterpriseAddress = 4,
        /// <summary>
        /// 申请人号码
        /// </summary>
        [Description("申请人号码")]
        ApplyPhone = 5,
        /// <summary>
        /// 单位固话
        /// </summary>
        [Description("单位固话")]
        FixedUnit = 6,
        /// <summary>
        /// 家庭固话
        /// </summary>
        [Description("家庭固话")]
        FamilyFixed = 7,
        /// <summary>
        /// 家人联系人号码
        /// </summary>
        [Description("家人联系人号码")]
        FamilyContractNumber = 8,
        /// <summary>
        /// 工作证明人号码
        /// </summary>
        [Description("工作证明人号码")]
        WorkCertNumber = 9,
        /// <summary>
        /// 紧急联系人号码
        /// </summary>
        [Description("紧急联系人号码")]
        EmergencyNumber = 10,


    }
View Code
 /// <summary>
    /// 第三方信息查询类型
    /// </summary>
    public enum ThirdInfoType
    {
        /// <summary>
        /// 人法网
        /// </summary>
        [Description("人法网")]
        [Include(ThirdInfoCategroyObjectType.ApplyID)]
        [Include(ThirdInfoCategroyObjectType.SpouseID)]
        [Include(ThirdInfoCategroyObjectType.EnterpriseName)]
        HumanNet = 1,

        /// <summary>
        /// 工商网
        /// </summary>
        [Description("工商网")]
        [Include(ThirdInfoCategroyObjectType.EnterpriseName)]
        IndustrialCommercialNet = 2,
        /// <summary>
        /// 网络查询
        /// </summary>
        [Description("网络查询")]
        [Include(ThirdInfoCategroyObjectType.ApplyID)]
        [Include(ThirdInfoCategroyObjectType.SpouseID)]
        [Include(ThirdInfoCategroyObjectType.EnterpriseName)]
        [Include(ThirdInfoCategroyObjectType.EnterpriseAddress)]
        [Include(ThirdInfoCategroyObjectType.ApplyPhone)]
        [Include(ThirdInfoCategroyObjectType.FixedUnit)]
        [Include(ThirdInfoCategroyObjectType.FamilyFixed)]
        [Include(ThirdInfoCategroyObjectType.FamilyContractNumber)]
        [Include(ThirdInfoCategroyObjectType.WorkCertNumber)]
        [Include(ThirdInfoCategroyObjectType.EmergencyNumber)]
        InfoNet = 3,
    }

 

枚举类型-用法

标签:tar   单位   info   flags   object   field   企业   led   gif   

原文地址:http://www.cnblogs.com/x-poior/p/6002739.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!