views:

837

answers:

6

My search for the meaning of DCO was quite fruitless, so I decided to ask here. In my Java application, there are many classes like EmployeeDetailsDto, EmployeeDetailsDao, but recently I also came across EmployeeDetailsDco. Does anyone know what does the DCO stand for?

A: 

I have never heard of DCO but is it Data Carrying Object just another name for DTO?

Bhushan
hey, I was asking first! :)
Peter Perháč
well, it looks exactly like a DTO... so you may be right after all. Data Carrying Object? Is that your guess or did you actually find this somewhere?
Peter Perháč
I thought of what C must be in DCO and carrying word came to my mind.
Bhushan
+2  A: 

DTO = Data Transfer Object

DAO = Data Access Object

DCO = Dynamically Configurable Object?

From the article

Dynamically configurable object (DCO)

an object whose implementation can change incrementally after it is running

  • consists of interface elements
  • public function
  • private function
  • private data along with all accessor functions
  • member functions support incremental changes to interface elements
  • adding, removing, or altering
Russ Cam
A: 

Refactor the Dtos and drop the DTO suffix.

You might want to change Dao to Store or something similar.

Firstly EmployeeSetails without Dto/dco on the end obviously is a value class holding values relating to an employee. Without another term it's obvious it's not a utility - which should be called something g like EmployeeDetailsUtil/Helper etc.

Your dao should be called EmployeeSetailsStore because that describes it's function a store of EmployeeSetsils. How or where it puts them is irrelevant they are hidden away in your code. If you really wanted to you could call it HibernateEmploteeDetaileStore etc if it used Hibernate. Your interface should be called EmployeeSetailsStore. Implementors or this interface would use the interface name as a start and add impl technology to that base name.

Last but not least String is a value here of a char array but adding Dto in this case is ugly and silly.

Only really well known acronyms like Url should ever be used. In the end Store can never be confusing while all the acronyms you mentioned don't make things clearer and in this case introduced co fusion and this coated time.

If you measure the typing using what I have suggested you actually type less characters and everything is clearer. always aim for clarity rather than terseness after all we are all fast typers so what's a few extra chars. In the end we spend more time Reading, understanding etc than typing so a few extra chars in a class name isn't going to reduce productivity at all ...

Don't skimp...do it properly from the beginning.

mP
this looks radical. why would you recommend this?
Peter Perháč
A: 

This might be Command Object.

Thomman
+1  A: 

All I can say is Data Carrying Object is not what DCO means, put "Data Carrying Object" in google and it doesn't return any hits.

Thus the terms has to be wrong.

Ok tried googling "Data Objects DCO"

and got this result, which would suggest DCO means "Data Change Objects"

My guess is a DCO is an object that holds changes, a "diff", of the Object's Data.

Robert Gould
this looks good :) +1
Peter Perháč
A: 

I just spoke to the guy who used to remember what this stands for. It's pretty ironic that he no longer does. Nor do any other people here in this company.

The explanation I could find was, that it's basically a DTO, but they wanted to use DCO to differentiate between DTOs used by Hibernate and DCOs used by external systems, in this case LDAP.

So I believe the meaning of DCO could really be, as Bhushan suggests, Data Carrying object or the like, and in this case it was indeed intended to be just another name for DTO. Answer accepted. Thanks for your time! I thought DCO was an accepted acronym widely used by developers but it turned out to be just this... sorry.

Edit


THE answer is Data Container Object, for those interested. I have caused enough stir in the company so eventually a colleague emailed the local originator of the DCO term and, if anyone still cares to find out, it stands for Data Container Object.

Peter Perháč
The madness of Java. All objects are supposed to contain data (and behaviour that operates on the data)!
John Topley
Well, most, not all do (marker objects like enums have just identity, no data, stateless objects just behavior), but I guess the point is that these objects do very little else. In olden days they'd be called "structs"... :)
StaxMan