I have a class which I currently use like a dto and I've to create another class with similar properties (less than the actual has), it's there a pattern related to this? I thought that an adapter would help but I couldn't realize how.
Class ONE {
ObjectA oa;
ObjectB ob;
ObjectC oc;
String id;
String name;
String someId;
String country;
}
Class TWO {
ObjectB ob;
ObjectC oc;
String name;
String someId;
String country;
}
Any clue?
Aucun commentaire:
Enregistrer un commentaire