NotifyCanExecuteChangedForAttribute
Ecng.ComponentModel
Placed alongside ObservablePropertyAttribute on a backing field: when the generated property changes, the generator calls RaiseCanExecuteChanged on the listed commands. Mirrors CommunityToolkit.Mvvm.ComponentModel.NotifyCanExecuteChangedForAttribute.
继承自: Attribute
构造函数
NotifyCanExecuteChangedForAttribute
public NotifyCanExecuteChangedForAttribute(string commandName)
notifyCanExecuteChangedForAttribute = NotifyCanExecuteChangedForAttribute(commandName)
Initializes a new instance of the NotifyCanExecuteChangedForAttribute class.
- commandName
- The command whose CanExecuteChanged must be raised.
NotifyCanExecuteChangedForAttribute
public NotifyCanExecuteChangedForAttribute(string commandName, string[] otherCommandNames)
notifyCanExecuteChangedForAttribute = NotifyCanExecuteChangedForAttribute(commandName, otherCommandNames)
Initializes a new instance of the NotifyCanExecuteChangedForAttribute class.
- commandName
- The command whose CanExecuteChanged must be raised.
- otherCommandNames
- Additional command names.
属性
CommandName
public string CommandName { get; }
value = notifyCanExecuteChangedForAttribute.CommandName
The primary command name.
OtherCommandNames
public string[] OtherCommandNames { get; }
value = notifyCanExecuteChangedForAttribute.OtherCommandNames
Additional command names.