Last post May 17, 2010 04:23 PM by atconway
May 15, 2010 11:54 AM|studotnet|LINK
We have a product with few customers. Customers have different implementations for same methods.
We thougt to use inheritance and we are not going to change the original implementation of the product.
for an example: OrderService (class)
OrderServiceClient1 : OrderServiceCompany
OrderServiceClient2 : OrderServiceCompany
We are maintaing different branches for different clients (as the example 2 branches). But the implementation of OrderServiceCompany would be same for both clients. If there is any deviation they have to use OrderServiceClient class.
If there is any method which we do not allow any modification to client, we can make it sealed.
Do you think, this is a wise model or any drawback with this design???
May 15, 2010 04:56 PM|thuhue|LINK
Please go ahead do it, test and find out.
May 17, 2010 04:23 PM|atconway|LINK
Customers have different implementations for same methods.
What about creating an Interface for OrderServiceCompany and implement the methods as needed for each client as needed? If you have a finite number of customers each with your own customized implementation then that should work.