⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 200442149.htm

📁 UML基础(好)
💻 HTM
📖 第 1 页 / 共 3 页
字号:
<TD><IMG src="2004421497.gif" tppabs="http://www.uml.org.cn/images/upfile/2004421497.gif"> </TD></TR>
<TR>
<TD align=middle><SPAN class=caption><B xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">Figure 6:</B> Activity diagram, with two swimlanes to indicate control of activity by two objects: the band manager, and the reporting tool </SPAN></TD></TR></TBODY></TABLE>
<P>In our example activity diagram, we have two swimlanes because we have two objects that control separate activities: a band manager and a reporting tool. The process starts with the band manager electing to view the sales report for one of his bands. The reporting tool then retrieves and displays all the bands that person manages and asks him to choose one. After the band manager selects a band, the reporting tool retrieves the sales information and displays the sales report. The activity diagram shows that displaying the report is the last step in the process. </P>
<P><A name=N101C6><SPAN class=atitle2><STRONG><FONT size=4>Component diagram</FONT></STRONG></SPAN></A><BR>A component diagram provides a physical view of the system. Its purpose is to show the dependencies that the software has on the other software components (e.g., software libraries) in the system. The diagram can be shown at a very high level, with just the large-grain components, or it can be shown at the component package level.<A href="javascript:if(confirm('http://www-106.ibm.com/developerworks/rational/library/769.html  \n\nThis file was not retrieved by Teleport Pro, because it is addressed on a domain or path outside the boundaries set for its Starting Address.  \n\nDo you want to open it from the server?'))window.location='http://www-106.ibm.com/developerworks/rational/library/769.html#footnotes'" tppabs="http://www-106.ibm.com/developerworks/rational/library/769.html#footnotes" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><SUP><FONT color=#996699>2</FONT></SUP></A> </P>
<P>Modeling a component diagram is best described through an example. Figure 7 shows four components: Reporting Tool, Billboard Service, Servlet 2.2 API, and JDBC API. The arrowed lines from the Reporting Tool component to the Billboard Service, Servlet 2.2 API, and JDBC API components mean that the Reporting Tool is dependent on those three components.</P>
<TABLE cellPadding=5 width=500>
<TBODY>
<TR>
<TD><IMG src="2004421498.jpg" tppabs="http://www.uml.org.cn/images/upfile/2004421498.jpg"> </TD></TR>
<TR>
<TD align=middle><SPAN class=caption><B xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">Figure 7:</B> A component diagram shows interdependencies of various software components the system comprises </SPAN></TD></TR></TBODY></TABLE>
<P></P>
<P><A name=N101FA><SPAN class=atitle2><STRONG><FONT size=4>Deployment diagram</FONT></STRONG></SPAN></A><BR>The deployment diagram shows how a system will be physically deployed in the hardware environment. Its purpose is to show where the different components of the system will physically run and how they will communicate with each other. Since the diagram models the physical runtime, a systems production staff will make considerable use of this diagram. </P>
<P>The notation in a deployment diagram includes the notation elements used in a component diagram, with a couple of additions, including the concept of a node. A node represents either a physical machine or a virtual machine node (e.g., a mainframe node). To model a node, simply draw a three-dimensional cube with the name of the node at the top of the cube. Use the naming convention used in sequence diagrams: [instance name] : [instance type] (e.g., w3reporting.myco.com : Application Server). </P>
<TABLE cellPadding=5 width=250>
<TBODY>
<TR>
<TD align=middle><A onclick=window.open(content/03July/2500/2772/2772_fig8.jpg,fig_8,height=481,width=770); href="javascript:if(confirm('http://www-106.ibm.com/developerworks/rational/library/769.html  \n\nThis file was not retrieved by Teleport Pro, because it is addressed on a domain or path outside the boundaries set for its Starting Address.  \n\nDo you want to open it from the server?'))window.location='http://www-106.ibm.com/developerworks/rational/library/769.html#'" tppabs="http://www-106.ibm.com/developerworks/rational/library/769.html#" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" false;; return><IMG src="2004421499.jpg" tppabs="http://www.uml.org.cn/images/upfile/2004421499.jpg" border=0><FONT color=#996699> </FONT></A></TD></TR>
<TR>
<TD align=middle><SPAN class=caption><B xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">Figure 8:</B> Deployment diagram. <I xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">Because the Reporting Tool component is drawn inside of IBM WebSphere, which in turn is drawn inside of the node w3.reporting.myco.com, we know that users will access the Reporting Tool via a browser running on their local machine, and connecting via HTTP over their companys intranet. </I></SPAN></TD></TR>
<TR>
<TD align=middle>(<A onclick=window.open(content/03July/2500/2772/2772_fig8.jpg,fig_8,height=481,width=770); href="javascript:if(confirm('http://www-106.ibm.com/developerworks/rational/library/769.html  \n\nThis file was not retrieved by Teleport Pro, because it is addressed on a domain or path outside the boundaries set for its Starting Address.  \n\nDo you want to open it from the server?'))window.location='http://www-106.ibm.com/developerworks/rational/library/769.html#'" tppabs="http://www-106.ibm.com/developerworks/rational/library/769.html#" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" false;; return><FONT color=#996699>click here to enlarge</FONT></A>) </TD></TR></TBODY></TABLE>
<P>The deployment diagram in Figure 8 shows that the users access the Reporting Tool by using a browser running on their local machine and connecting via HTTP over their companys intranet to the Reporting Tool. This tool physically runs on the Application Server named w3reporting.myco.com. The diagram shows the Reporting Tool component drawn inside of IBM WebSphere, which in turn is drawn inside of the node w3.reporting.myco.com. The Reporting Tool connects to its reporting database using the Java language to IBM DB2s JDBC interface, which then communicates to the actual DB2 database running on the server named db1.myco.com using native DB2 communication. In addition to talking to the reporting database, the Report Tool component communicates via SOAP over HTTPS to the Billboard Service.</P>
<P><A name=N10243><SPAN class=atitle2><STRONG><FONT size=4>Conclusion</FONT></STRONG></SPAN></A><BR>Although this article provides only a brief introduction to Unified Modeling Language, I encourage you to start applying the information you have learned here to your own projects and to dig more deeply into UML. There are several software tools that help you to integrate UML diagrams into your software development process, but even without automated tools, you can use markers on a whiteboard or paper and pencils to draw your UML diagrams and still achieve benefits. </P><A name=footnotes xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"></A>
<P><A name=N10250><SPAN class=atitle2><STRONG><FONT size=4>Notes</FONT></STRONG></SPAN></A><BR><SUP><STRONG>1</STRONG></SUP> For more information on inheritance and other object-oriented principles, see <A href="javascript:if(confirm('http://java.sun.com/docs/books/tutorial/java/concepts/inheritance.html  \n\nThis file was not retrieved by Teleport Pro, because it is addressed on a domain or path outside the boundaries set for its Starting Address.  \n\nDo you want to open it from the server?'))window.location='http://java.sun.com/docs/books/tutorial/java/concepts/inheritance.html'" tppabs="http://java.sun.com/docs/books/tutorial/java/concepts/inheritance.html" target=new xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><FONT color=#006699>http://java.sun.com/docs/books/tutorial/java/concepts/inheritance.html</FONT></A></P>
<P><SUP><B xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">2</B></SUP> The phrase component package level is a programming language-neutral way of referring to class container levels such as .NETs namespaces (e.g., System.Web.UI) or Javas packages (e.g., java.util).</P>
<P><A name=N10268><SPAN class=atitle2><STRONG><FONT size=4>Resources</FONT></STRONG></SPAN></A><BR><A href="javascript:if(confirm('http://www.uml.org/  \n\nThis file was not retrieved by Teleport Pro, because it is addressed on a domain or path outside the boundaries set for its Starting Address.  \n\nDo you want to open it from the server?'))window.location='http://www.uml.org/'" tppabs="http://www.uml.org/" target=new xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><FONT color=#006699>http://www.uml.org/</FONT></A> ?The official UML Web site.<BR xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><A href="javascript:if(confirm('http://www.rational.com/uml/resources/documentation/index.jsp  \n\nThis file was not retrieved by Teleport Pro, because it is addressed on a domain or path outside the boundaries set for its Starting Address.  \n\nDo you want to open it from the server?'))window.location='http://www.rational.com/uml/resources/documentation/index.jsp'" tppabs="http://www.rational.com/uml/resources/documentation/index.jsp" target=new xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><FONT color=#006699>http://www.rational.com/uml/resources/documentation/index.jsp</FONT></A> 桹ffers several different versions of the actual UML specification.<BR xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><A href="javascript:if(confirm('http://www-140.ibm.com/developerworks/rational/products/rose  \n\nThis file was not retrieved by Teleport Pro, because it is addressed on a domain or path outside the boundaries set for its Starting Address.  \n\nDo you want to open it from the server?'))window.location='http://www-140.ibm.com/developerworks/rational/products/rose'" tppabs="http://www-140.ibm.com/developerworks/rational/products/rose" target=new xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><FONT color=#006699>http://www-140.ibm.com/developerworks/rational/products/rose</FONT></A> 桰nformation on IBM Rational Rose,<SUP>?/SUP&gt; A commercial UML modeling tool.<BR xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><A href="javascript:if(confirm('http://www-140.ibm.com/developerworks/rational/products/xde  \n\nThis file was not retrieved by Teleport Pro, because it is addressed on a domain or path outside the boundaries set for its Starting Address.  \n\nDo you want to open it from the server?'))window.location='http://www-140.ibm.com/developerworks/rational/products/xde'" tppabs="http://www-140.ibm.com/developerworks/rational/products/xde" target=new xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><FONT color=#006699>http://www-140.ibm.com/developerworks/rational/products/xde</FONT></A>桰nformation on IBM Rational XDE,<SUP>?/SUP&gt; a commercial UML modeling tool that is integrated with IBMs Eclipse development platform.<BR xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><A href="javascript:if(confirm('http://argouml.tigris.org/  \n\nThis file was not retrieved by Teleport Pro, because it is addressed on a domain or path outside the boundaries set for its Starting Address.  \n\nDo you want to open it from the server?'))window.location='http://argouml.tigris.org/'" tppabs="http://argouml.tigris.org/" target=new xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><FONT color=#006699>http://argouml.tigris.org/</FONT></A> 桰nformation on Argo UML, an .open source UML modeling tool built in Java.<BR xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><A href="javascript:if(confirm('http://uml.sourceforge.net/index.php  \n\nThis file was not retrieved by Teleport Pro, because it is addressed on a domain or path outside the boundaries set for its Starting Address.  \n\nDo you want to open it from the server?'))window.location='http://uml.sourceforge.net/index.php'" tppabs="http://uml.sourceforge.net/index.php" target=new xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><FONT color=#006699>http://uml.sourceforge.net/index.php</FONT></A> ?Information on Umbrello UML Modeller, an open source UML modeling tool for KDE. </P>
<P>Click <A href="javascript:if(confirm('http://www-106.ibm.com/developerworks/rational/library/content/03July/2500/2772/2772_uml.pdf  \n\nThis file was not retrieved by Teleport Pro, because it is addressed on a domain or path outside the boundaries set for its Starting Address.  \n\nDo you want to open it from the server?'))window.location='http://www-106.ibm.com/developerworks/rational/library/content/03July/2500/2772/2772_uml.pdf'" tppabs="http://www-106.ibm.com/developerworks/rational/library/content/03July/2500/2772/2772_uml.pdf" target=new xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><FONT color=#006699>here</FONT></A> to view a PDF version of this article.</P>
<P>
<HR>

<P></P>
<P><I xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><B>Editors Note:</B> This article originally appeared in <A href="javascript:if(confirm('http://www.therationaledge.com/  \n\nThis file was not retrieved by Teleport Pro, because it is addressed on a domain or path outside the boundaries set for its Starting Address.  \n\nDo you want to open it from the server?'))window.location='http://www.therationaledge.com/'" tppabs="http://www.therationaledge.com/" target=new><FONT color=#006699>The Rational Edge</FONT></A>.</I></P>
<P></P>
<TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
<TBODY>
<TR>
<TD><A name=author1></A><STRONG><FONT size=4><SPAN class=atitle2>About the author</SPAN><BR></FONT></STRONG>Donald Bell is an IT Specialist in IBM Global Services, where he works with IBMs customers to design and develop J2EE based software solutions. In his spare time he attempts to catch up with the yard work at his new house in Arkansas. </TD></TR></TBODY></TABLE>
<DIV></DIV></SUP></SUP></SUP></td>
  </tr>
</table>
<table width="760" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td align="center">
<hr>
      <span class="copyright"> 版权所有:UML软件工程组织 </span></td>
  </tr>
</table>
</body>
<!-- InstanceEnd --></html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -