コード例 #1
0
        public void Process(Ledger ledger)
        {
            var orders = ledger.Get();

            foreach (var order in orders)
            {
                if (order.IsValid())
                {
                    _orderProcessor.Accept(order);
                }
                else
                {
                    _orderProcessor.Decline(order);
                }
            }
        }