Class RelayCommand
public class RelayCommand : CommandBase, ICommand
- Inheritance
-
RelayCommand
- Implements
- Derived
- Inherited Members
- Extension Methods
Constructors
RelayCommand(Action<object>)
public RelayCommand(Action<object> action)
Parameters
RelayCommand(Action<object>, Predicate<object>)
public RelayCommand(Action<object> execute, Predicate<object> canExecute)
Parameters
Fields
_action
protected Action<object> _action
Field Value
_canExecute
protected readonly Predicate<object> _canExecute
Field Value
Methods
CanExecute(object)
Defines the method that determines whether the command can execute in its current state.
public override bool CanExecute(object parameter)
Parameters
parameter
objectData used by the command. If the command does not require data to be passed, this object can be set to null.
Returns
Execute(object)
Defines the method to be called when the command is invoked.
public override void Execute(object parameter)