I am finally beginning to put CSLA into real-world use, but I am confused on one point.
Doesn't every business object have methods that interact with data that don't fit nicely into a fetch,update etc?
Where do methods such as these go?
For example, in the past when I created business logic, I would often create them in three classes: object, object list, and object data acces. Using a Carrier business object as an example I would end up with:
Carrier
CarrierList
CarrierDAO
The relevant part to this post lies inside CarrierDAO.
There is a method in there called CustNumFromTrackNum. It grabs a tracking number from the data source (based upon criteria passed in), from that tracking number it extracts a customer number and that customer number is what is returned from that method.
So where would I put a method such as this using CSLA.
thanks for any help, Ryan
Thank you for your reply.
What I'm worried about is mudying up the business object with a whole bunch of "helper methods".
It makes me think that maybe I am designing my BO's incorrectly (I'm new to all this...).
So, do you think that helper methods inside a business object are fine as long as they are private?
Helper methods are a necessary evil and should not be viewed as bad design, right??
thanks again, Ryan
Copyright (c) Marimer LLC