using System; namespace Abp.Application.Features { /// /// This attribute can be used on a class/method to declare that given class/method is available /// only if required feature(s) are enabled. /// [AttributeUsage(AttributeTargets.Class | AttributeTargets.Method)] public class RequiresFeatureAttribute : Attribute { /// /// A list of features to be checked if they are enabled. /// public string[] Features { get; private set; } /// /// If this property is set to true, all of the must be enabled. /// If it's false, at least one of the must be enabled. /// Default: false. /// public bool RequiresAll { get; set; } /// /// Creates a new instance of class. /// /// A list of features to be checked if they are enabled public RequiresFeatureAttribute(params string[] features) { Features = features; } } }