I am using simple 3 tier architecture. In this I am using DTO classes to communicate between UI,BL and DL. So there is any better way for communication between layers? or this is the right way?
The 3-tier architecture refers to the logical 3-tier system rather than the physical ones. It adds a “middle tier” between the client and the database. The main functions and business logic of the system are processed in the middle layer, which is the application layer.
It divides the architecture into three tiers: data layer, application layer, and presentation layer. The 3-tier architecture refers to the logical 3-tier system rather than the physical ones.
A 3-tier architecture is an architecture pattern used in applications as a specific type of client-server system. It divides the architecture into three tiers: data layer, application layer, and presentation layer. The 3-tier architecture refers to the logical 3-tier system rather than the physical ones.
In a three-tier application, all communication goes through the application tier. The presentation tier and the data tier cannot communicate directly with one another. In discussions of three-tier architecture, layer is often used interchangeably – and mistakenly – for tier, as in 'presentation layer' or 'business logic layer.'
DTO, Data transfer Object, is the concept for distribution layer, you use when transferring data between your consumers and your service. So, if you don't publish any service, get off DTO.
To answer your question, it also depends on how complex your application is. If it's simple, just use CRUD operation, or you can even use DataTable
, DataSet
for communication.
Otherwise, Domain Entity from DDD is the core object for communication between layers: Data Access Layer, Business Logic Layer and Presentation Layer.
Basically, there are some different type of objects in application:
Be careful with the term:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With