Long Winded Background (sorry
)
A conviction that I've developed over the last 10 years in the industry is the importance of creating and consistently employing accurate metaphors in the design process. I’m not suggesting that metaphors are silver bullets to achieve quality software or anything as radical as that. That said, in my experience, the right metaphors go a long way in perpetuating the overall vision for a project while the wrong metaphors can contribute to confusion in the best case and poor design choices in the worst case.
Many of us use the Tier metaphor in the design process and one of the ways we implement the metaphor is through naming conventions for our assemblies and namespaces.
I'm using the adapter model employed by LLBLGen Pro and after a lot of thought I've started to see the DB specific code as a part of the DAL and the generic code as part of the BLL. The details of interacting with the data store directly and moving data in and out of entities is what the DB specific code and the DQE's are all about (as I understand it) so, conceptually, I see them as part of the DAL. On the other hand, the entities that are a part of the generic code generated for adapter seem totally wired for the BLL.
The Actual Questions
This brings me to my 2 questions for all of you.
I'd like to implement this Tier metaphor through the assembly/namespace names of the 2 projects of the adapter code in the following way...
<Company>.<Product>.Core (generic code)
<Company>.<Product>.Data.<Database> (database specific code)
We use 'Core' as the suffix for BLL assemblies and 'Data' as the suffix for DAL assemblies.
Question 1: After reading through the forums I found some posts on this issue but it really wasn't clear to me from them exactly how I could achieve the above. As I see it, the key impediment is the fact that the project properties in LLBLGen Pro provide a way to specify a DB specific suffix but no way to specify a suffix for the generic code.
Question 2: The entities in the generic code offer so much goodness for the presentation tier in the form of implementations for IBindingList, IEditableObject, save points for field data, etc. However, I've already had several occasions where I need to create a BLL class that's a hybrid of one or more entities. I'd like these hybrid BLL classes to be able to have the same goodness that the entities have w/o having to code it all from scratch. Is there a way to leverage the goodness in the entities in my custom BLL classes w/o re-inventing the wheel so-to-speak?