using System;
using System.Runtime.InteropServices;
namespace DeviceRepair.Models.Attr
{
///
/// 枚举描述特性
///
[Serializable]
[AttributeUsage(AttributeTargets.Field | AttributeTargets.Enum, AllowMultiple = false, Inherited = false)]
[ComVisible(true)]
public class ComboBoxItemAttribute : Attribute
{
private string _Caption;
///
/// 枚举描述
///
public string Caption
{
get { return _Caption; }
set { _Caption = value; }
}
private bool _IsIgnore;
///
/// 是否忽略
///
public bool IsIgnore
{
get { return _IsIgnore; }
set { _IsIgnore = value; }
}
public ComboBoxItemAttribute() : this("", false)
{
}
public ComboBoxItemAttribute(string caption, bool isIgnore)
{
Caption = caption;
IsIgnore = isIgnore;
}
}
}