Adding a controller factory to ASP MVC

前端 未结 2 1720
情话喂你
情话喂你 2020-11-30 12:29

I have a design idea for a large project at work and I think I have it figured out but would really love to get some feedback on a) the idea in general, and b) my proposed i

2条回答
  •  旧巷少年郎
    2020-11-30 12:52

    There is nothing wrong with the idea of a controller factory, as long as it is simply for flexibility later. the problem si when you load up the controllers with code that belongs in other layers, which is one reason you might "need" the flexibility of other controllers. As long as you are not mashing layers togehter, I see no real issue with the factory idea.

提交回复
热议问题