aspose file tools*
The moose likes Architect Certification (SCEA/OCMJEA) and the fly likes Big Smokes Domain Model Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Certification » Architect Certification (SCEA/OCMJEA)
Bookmark "Big Smokes Domain Model" Watch "Big Smokes Domain Model" New topic
Author

Big Smokes Domain Model

J J Wright
Ranch Hand

Joined: Jul 02, 2008
Posts: 254
Hi,

As some people have already pointed out in other posts, the relationships between StandardCigar, PetiteCigar, FlavoredCigar and CigarManufacturer is many-to-many. This raises several issues:

A many-to-many relationship like this works fine for the components of a final product but it doesn't really fit for a finished product like a cigar. The many-to-many relationship implies that Big Smokes only sells generic cigars. For example, when I buy a standard cigar I'll have no idea who made it until it arrives on my doorstep. Clearly this isn't a very sensible business model. For example, people don't go into a shop and ask for a packet of cigarettes, only to leave the choice of brand up to the salesperson.

An alternative interpretation of the business model is that StandardCigar, PetiteCigar, and FlavoredCigar all relate to product categories, as opposed to individual saleable items. This makes far more sense.

Also, I think it's safe to assume that the perspective of the domain model class diagram supplied by Sun is conceptual, rather than specification or implementation. This gives us some leeway in how we interpret it's contents.

What are other peoples' thoughts on this?

Regards,

Jonathan

SCJP, SCWCD, SCBCD, SCEA 5
Eduardo Plata
Greenhorn

Joined: Nov 19, 2004
Posts: 17
I am agree with the idea that Standard, Petite and Flavored are categories of a product. Thinking in a new cigar it will be so expensive to have an entity for each type. Then I have changed my BDM to support a new entity called product that has a category (Product[*]:Category[1]). But now, is that possible? as you say is it safe to think that BDM is a conceptual model?

Many to Many relation, as you say gives the customer the absence of brand, then BigSmokes Cigars only has three products to sale, this for me has no sense, moreover you will have to ask for inventory of the same product in all manufacturers and it is so expensive. I think a product should be identified by a category(standard, petit, flavored) and a manufacturer, are you agree?.

Greetings.
J J Wright
Ranch Hand

Joined: Jul 02, 2008
Posts: 254
I totally agree.

In my mind StandardCigar, PetiteCigar, and FlavoredCigar have to be categories of product. Whichever way you look at it they just don't make sense as saleable items. I raised the question because this seemed to be an issue other people were grappling with.

I also believe the class model is 100% conceptual in nature (it was created by business analysts). As has already been mentioned; there's no way you're going to create a catalogue system based on non-generic objects like these.
Lann Lu
Ranch Hand

Joined: May 31, 2008
Posts: 45
Jonathan
I totally agree with you. What you say here makes a lot of sense.
Actually I thought about this the same way as well, but wasn't that sure. The assumption is reasonable, therefore the products(not category) to manufacturer is many-to-one. This simplifies things. But remember it still stands that one Order may involve multiple manufacturers.

Btw, what makes you afraid of speaking out of my name, keep referring me as "other".

Peace,
J J Wright
Ranch Hand

Joined: Jul 02, 2008
Posts: 254
Hi Lann,

Btw, what makes you afraid of speaking out of my name, keep referring me as "other".


Hey, nothing personal. I was trying to write replies on the fly and couldn't be bothered linking all the threads together! Get's a little confusing now there's 2 or 3 on the same topic :-) It's good that there's strong consensus on how to interpret the Domain Model.

Regards,

Jonathan
Lann Lu
Ranch Hand

Joined: May 31, 2008
Posts: 45
Hi, Jonathan,

Not a problem, I was just curious.
Thanks again for helping me think through.

Cheers,
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Big Smokes Domain Model