必然,我必须在每一层(DAL,BL,FRONT或Presentation,Services,UnitOfWork等)中实现异步方法吗?
我该怎么办?
选项1:
//Front:
- public async method() { //calling await methodMiddle() }
//BL-Domain-Whatever:
- public async methodMiddle() { //calling await methodDAL() }
//DAL-Persistence-Whatever
- public async methodDAL()
选项2:
//Front:
- public async method() ASYNC { //calling methodMiddle() }
//BL-Domain-Whatever: NO ASYNC
- public methodMiddle() { //calling methodDAL() }
//DAL-Persistence-Whatever: NO ASYNC
- public methodDAL()
先谢谢!!