using System;

namespace VCommon.Reflection
{
    [AttributeUsage(AttributeTargets.Field)]
    public sealed class EnumMetaAttribute : Attribute
    {
        /// <summary>
        /// 界面文本
        /// </summary>
        public string Text { get; }

        /// <summary>
        /// 排序
        /// </summary>
        public int Sort { get; }

        /// <summary>
        /// 额外信息
        /// </summary>
        public string Tag { get; }

        /// <summary>
        /// 导出元数据时忽略该成员
        /// </summary>
        public bool DoNotExport { get; set; }

        /// <summary>
        ///
        /// </summary>
        public EnumMetaAttribute(string text, int sort = 0, string tag = null)
        {
            Text = text;
            Sort = sort;
            Tag = tag;
        }
    }
}