/// <summary> /// Creates a new <see cref = "DelegatePCommand" />. /// </summary> /// <param name = "action">An implementation of the <see cref = "PCommand.Run" /> method.</param> /// <param name = "isPure">A boolean value indicating whether the command is to be treated like a pure function.</param> /// <exception cref = "ArgumentNullException"><paramref name = "action" /> is null.</exception> public DelegatePCommand(PCommandAction action, bool isPure) { if (action == null) throw new ArgumentNullException("action"); _action = action; }
/// <summary> /// Creates a new <see cref = "DelegatePCommand" />. /// </summary> /// <param name = "action">An implementation of the <see cref = "PCommand.Run" /> method.</param> /// <exception cref = "ArgumentNullException"><paramref name = "action" /> is null.</exception> public DelegatePCommand(PCommandAction action) : this(action, false) { }