Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How should business level objects be named?

We are building a service-oriented system where we have separated the application into several layers:

  1. SOAP web services (e.g., BuildingService.asmx)
  2. Business logic layer (e.g., BuildingXXX)
  3. Data Access layer (e.g, BuildingProvider)
  4. Types (e.g., Building)

The SOAP web services simply instantiate an object of type BuildingXXX from the business logic layer in order to keep the implementation out of the SOAP web services. BuildingXXX then uses the BuildingProvider from the data access layer to return types defined in the data transfer object layer.

We have been unable to determine what we should call the objects in the business logic layer.

What is the "standard" naming convention for naming these business level entities?

like image 951
Ryan Taylor Avatar asked Dec 05 '25 15:12

Ryan Taylor


2 Answers

Personally, I would call your business logic layer services "BuildingService" then call the web services "BuildingWebService".

Or you could always go with the generic "BuildingManager" as well for the service layer..

like image 150
Eric Petroelje Avatar answered Dec 08 '25 16:12

Eric Petroelje


Namespaces are your friends. How about BusinessLayer.Building, BusinessLayer.Facility? Use DataLayer.Building, DataLayer.Facility, etc. You get to call things what they are, yet they get to be different things.

like image 34
John Saunders Avatar answered Dec 08 '25 17:12

John Saunders



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!