• 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
  • Paul Clapham
  • Ron McLeod
  • paul wheaton
  • Devaka Cooray
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Liutauras Vilda
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Piet Souris
Bartenders:
  • salvin francis
  • Mikalai Zaikin
  • Himai Minh

UML representation of EJB and JSPs

 
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
How should we be representing EJBs on our class diagrams. After searching through a number of different books and resources on how to represent the J2EE components in UML in particular class diagrams I have found the following suggestions:
For EJB
1) Class diagram should not show implementation details leave the specifics to the component diagram.
2)Show each element (remote, home , bean [,primary key])as a seperate class on the diagram use the EJBRealizeRemote and EJBRealizeHome <<stereotypes>>
3) Use the folder symbol stereotype it with EJBEntityBean or EJBSessionBean (probably even EJBMessageBean) and place the Remote, Home and optionally Primary Key Class inside. (This is used in the book Developing Enterprise Applications with J2EE and UML by Khawar Ahmed and Cary Umrysh which I am sure will become recommended reading for this certification)
4) Show all the methods home, remote and bean on the same class element. These additional dividers (horizontal lines) are added to seperate the different methods catagories. (Together 4.2 approach)
JSP
1) dont put them on a class diagram they should only be on the class diagram.
2) JSPs are split into a ServerPage and a ClientPage element. The serverPage is the compiled component which runs in the container and the clientpage is the html page it produces. This server page can additionally be shown to be an agregation of forms, headers and footers. (Approach used in book)
3) Model them as you would servelts but with the JSP sterotype
I am inclined to feel that Home and Remote interfaces add clutter and am inclined to want them off the class diagrams. The Idea of splitting the JSP into two elements makes little sense to me and again adds clutter. So I would go no JSPs on class diagram and represent EJB as a class and show more information on the component diagram.
What approach do other people use/suggest.
Carl

 
Ranch Hand
Posts: 138
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by carl marais:

3) Use the folder symbol stereotype it with EJBEntityBean or EJBSessionBean (probably even EJBMessageBean) and place the Remote, Home and optionally Primary Key Class inside. (This is used in the book Developing Enterprise Applications with J2EE and UML by Khawar Ahmed and Cary Umrysh which I am sure will become recommended reading for this certification)


For stereotype, I refer to the Sun EJB/UML mapping
http://developer.java.sun.com/developer/technicalArticles/J2EE/patterns/UseOfUML.html
and I invite you to download and take a look to the draft pdf file from http://jcp.org/aboutJava/communityprocess/review/jsr026/
Regards,

 
You showed up just in time for the waffles! And this tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
reply
    Bookmark Topic Watch Topic
  • New Topic