• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

question regarding OOAD

 
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I have some domain objects and service objects. When drawing an interaction diagram, do we need to show service objects also or can we skip showing service objects in interaction diagram??
For ex, i have a service object called dboperations which provides interface to the required database and provides all the methods needed to interact with the database. I use this object whenever i wanted to make a connection to the database. Whenever a domain object receives a message to get some information, the domain object sends a corresponding message to service object.
Bye
Madhu
 
author
Posts: 3892
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
IMHO,
It's WAYYY clearer if you show all objects in an interaction diagram. Skipping objects leads you to a mess of trouble when you try to move to implementation...
However, one caveat -- you don't have to repeat the details of a method you've described in another diagram. If you've shown the complete flow for (for instance) obtaining a connection from a pool in one diagram, you can just use "getConnection" in other diagrams.
Kyle
------------------
Kyle Brown,
Author of Enterprise Java (tm) Programming with IBM Websphere
See my homepage at http://members.aol.com/kgb1001001 for other WebSphere information.
[This message has been edited by Kyle Brown (edited October 17, 2001).]
 
Ranch Hand
Posts: 67
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I accept the point that leaving out elements can cause problems later on. However, I still like to give designers some flexibility. It all depends on what you are trying to show, and who your audience is.
If you are showing a detailed UC realisation, that is mapped to code - then you will probably show all the nitty-gritty details.
However, if you are showing an architectural diagram - then it may be acceptable to leave out some information.
paul.
 
Kyle Brown
author
Posts: 3892
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I'll agree with Paul with one caveat -- your design should be layered well enough that it's kind of obvious where to "stop" with providing detail in the diagram. For isntance, I generally employ the Facade pattern quite a bit because it gives a good notion of where you can stop in providing detail at the highest level.
So, for instance, I'll often use a "database broker" facade that hides all of the details of O/R mapping for my objects, and I'll only show the presence of the facade (not any of the details) at the architectural level.
Likewise I'll usually do the same for UI (Showing lines on my diagrams coming in from a "controller" that is independent of the actual buttons and windows).
Kyle
------------------
Kyle Brown,
Author of Enterprise Java (tm) Programming with IBM Websphere
See my homepage at http://members.aol.com/kgb1001001 for other WebSphere information.
 
Paul Newton
Ranch Hand
Posts: 67
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
In My Humble/Honest Opinion...
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic