public IServiceCollection Bootstrap(IServiceCollection services)
        {
            services.AddScoped <OrdersConfig>((serviceProvider) =>
            {
                var config       = serviceProvider.GetRequiredService <IConfiguration>();
                var ordersConfig = new OrdersConfig();
                config.Bind("Orders", ordersConfig);

                return(ordersConfig);
            });

            return(services);
        }
Exemple #2
0
 public OrdersAPIController(OrdersConfig config)
 {
     this.tableStorageProvider = new TableStorageProvider <OrderTableEntity>(config);
 }
 internal TableStorageProvider(OrdersConfig config)
 {
     this.config = config;
 }