Exemple #1
0
        public SearchCriteria ValidateAddress(SearchCriteria criteria)
        {
            ValidateAddressCommand validateAddressCommand = new ValidateAddressCommand(criteria);

            validateAddressCommand.Execute();
            return(validateAddressCommand.CommandResult);
        }
Exemple #2
0
        public void Consume(IConsumeContext <MemberAddressAdded> context)
        {
            Console.WriteLine("Do some address validation here for: {0}", context.Message.MemberId);

            var command = new ValidateAddressCommand(NewId.NextGuid(), DateTime.UtcNow, context.Message.MemberId);

            context.Bus.ScheduleMessage(DateTime.UtcNow + TimeSpan.FromSeconds(5), command);
        }