简体   繁体   中英

What design pattern will fit to convert data table to list of domain objects?

I have a service that calls database to retrieve data; this service will return data as data table. Now I want to implement design pattern that fit in between my client and the service so it will convert these data tables to list of domain object. Which design pattern will fit here as a wrapper for this service by exposing data table as list of objects?

我想你需要适配器模式

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM