public DeleteCommand(ClientTransaction clientTransaction, DomainObject deletedObject, IClientTransactionEventSink transactionEventSink)
        {
            ArgumentUtility.CheckNotNull("clientTransaction", clientTransaction);
            ArgumentUtility.CheckNotNull("deletedObject", deletedObject);
            ArgumentUtility.CheckNotNull("transactionEventSink", transactionEventSink);

            _clientTransaction    = clientTransaction;
            _deletedObject        = deletedObject;
            _transactionEventSink = transactionEventSink;

            _dataContainer = _clientTransaction.DataManager.GetDataContainerWithLazyLoad(_deletedObject.ID, throwOnNotFound: true);
            Assertion.IsFalse(_dataContainer.State == StateType.Deleted);
            Assertion.IsFalse(_dataContainer.State == StateType.Invalid);

            _endPoints = (from endPointID in _dataContainer.AssociatedRelationEndPointIDs
                          let endPoint = _clientTransaction.DataManager.GetRelationEndPointWithLazyLoad(endPointID)
                                         select endPoint).ToArray();
            _endPointDeleteCommands = new CompositeCommand(_endPoints.Select(endPoint => endPoint.CreateDeleteCommand()));
        }
        private ExpandedCommand(CompositeCommand compositeCommand)
        {
            ArgumentUtility.CheckNotNull("compositeCommand", compositeCommand);

            _compositeCommand = compositeCommand;
        }