public DomainEventsController(MetaDbContext metaDbContext, CodeGenDbContext codeGenDbContext, IMapper mapper, ICodeGenerator generator) { _metaDbContext = metaDbContext; _codeGenDbContext = codeGenDbContext; _mapper = mapper; _generator = generator; }
public ValueObjectsController(MetaDbContext metaDbContext, CodeGenDbContext codeGenDbContext, IMapper mapper, ICodeGenerator generator) { _metaDbContext = metaDbContext; _codeGenDbContext = codeGenDbContext; _mapper = mapper; _generator = generator; }
public CodeTemplateCreatedHandler(CodeGenDbContext db) { Ensure.That(db).IsNotNull(); _db = db; }
public GetCodeTemplatesBySourceTypeHandler(CodeGenDbContext db) { Ensure.That(db).IsNotNull(); _db = db; }
public TemplatesController(CodeGenDbContext codeGenDbContext, IMapper mapper) { _codeGenDbContext = codeGenDbContext; _mapper = mapper; }
// This method gets called by the runtime. Use this method to configure the HTTP request pipeline. public void Configure(IApplicationBuilder app, IWebHostEnvironment env, MetaDbContext metaDbContext, CodeGenDbContext codeGenDbContext) { if (env.IsDevelopment()) { app.UseDeveloperExceptionPage(); } app.UseSwagger(); app.UseSwaggerUI(c => { c.SwaggerEndpoint("/swagger/v1/swagger.json", "DoMeta API V1"); }); // Ensure that query db is created metaDbContext.Database.EnsureCreated(); codeGenDbContext.Database.EnsureCreated(); // Use Kledex and ensure that domain db is created app.UseKledex().EnsureDomainDbCreated(); app.UseHttpsRedirection(); app.UseRouting(); app.UseCors("Cors"); app.UseAuthorization(); app.UseEndpoints(endpoints => { endpoints.MapControllers(); }); }