Esempio n. 1
0
        public void End()
        {
            this.EnsureCanExecute();

            _unloadDataCommand.End();
            _transactionEventSink.RaiseObjectsUnloadedEvent(Array.AsReadOnly(_domainObjects));
        }
        /// <summary>
        /// Raises all events and performs the action of the given <see cref="IDataManagementCommand"/>.
        /// The order of events is as follows: <see cref="IDataManagementCommand.Begin"/>,
        /// <see cref="IDataManagementCommand.Begin"/>, <see cref="IDataManagementCommand.Perform"/>,
        /// <see cref="IDataManagementCommand.End"/>, <see cref="IDataManagementCommand.End"/>.
        /// </summary>
        /// <param name="command">The command to be executed.</param>
        public static void NotifyAndPerform(this IDataManagementCommand command)
        {
            ArgumentUtility.CheckNotNull("command", command);

            command.Begin();
            command.Perform();
            command.End();
        }
Esempio n. 3
0
 public void End()
 {
     _decoratedCommand.End();
 }