Esempio n. 1
0
 public ControllerSourceUnit()
 {
     Requests = new SourceUnitCollection();
     RequestToCommandMappers = new SourceUnitCollection();
     Responses = new SourceUnitCollection();
     ResultToResponseMappers = new SourceUnitCollection();
 }
Esempio n. 2
0
            public IEnumerable <SourceUnit> GetAllUnits()
            {
                var result = new SourceUnitCollection();

                result.Append(Controller);
                result.Append(Requests);
                result.Append(RequestToCommandMappers);
                result.Append(Responses);
                result.Append(ResultToResponseMappers);
                return(result);
            }
        public SourceUnitCollection Generate(IEnumerable <ServiceInfo> serviceInfos)
        {
            SourceUnitCollection collection = new SourceUnitCollection();

            foreach (var sourceUnit in serviceInfos.SelectMany(_cqrsControllerGenerator.Generate))
            {
                collection.Append(sourceUnit);
            }

            return(collection);
        }
Esempio n. 4
0
        public async Task <SourceUnitCollection> Generate(long version)
        {
            SourceUnitCollection collection = new SourceUnitCollection();

            foreach (var proc in await _repo.Query <ProcedureDescriptor>().ToArrayAsync())
            {
                foreach (var u in await GenerateCqrsHandlerForProcedure(proc))
                {
                    collection.Append(u);
                }
            }

            return(collection);
        }