Vẽ sequence diagram bằng visio

Gói neftekumsk.com Visio 2 Gói Visio 1 neftekumsk.com Visio Professional 2021 Visio Professional 2019 Visio Professional 2016 Visio Professional 2013 Visio 2007 Xem thêm...Ít hơn

A UML sequence diagram shows how a set of objects interact in a process over time. It shows the messages that pass between participants & objects in the system, và the order in which they occur.

Bạn đang xem: Vẽ sequence diagram bằng visio

*


To build a sequence diagram, use a UML Sequence template or starter diagram, which includes the UML Sequence stencil. Drag shapes from the stencil onto the drawing canvas khổng lồ build the diagram.

Start a sequence diagram

Start Visio. Or if you have a file open already, clichồng File > New.

In the Search box, type UML sequence.

Select the UML Sequence diagram.

In the dialog box, select the blank template or one of the three starter diagrams. (A description of each one is shown on the right when you select it.) Then select either Metric Units or US Units.

Select Create.

The diagram opens. You should see the Shapes window next to lớn the diagram. If you don’t see it, go lớn View > Task Panes & make sure that Shapes is selected. If you still don’t see it, cliông chồng the Expvà the Shapes window button on the left.

On the View tab, make sure the kiểm tra box next to Connection Points is selected. This option makes connection points appear when you start connecting shapes.

Now, drag shapes you want khổng lồ include in your diagram from the Shapes window lớn the page. To rename text labels, double-cliông xã the labels.

Lifelines for actors and objects

Use an Actor lifeline shape for each participant, & an Object lifeline shape for each system component in your process.




Attach the beginning endpoint khổng lồ the lifeline sending the message, then drag the head endpoint to lớn the lifeline receiving the message.

Double-cliông chồng the message shape lớn create a text box, và type a name for the message.

Use a Message shape (a solid line) khổng lồ represent a request or the transmitting of information.

Use a Return Message shape (a dashed line) khổng lồ represent a response lớn a prior message.

Use a Self Message khổng lồ represent a recursive sầu Điện thoại tư vấn of an operation, or one method calling another method belonging khổng lồ the same object.

Use the Asynchronous Message shape khổng lồ show when an action might not happen immediately.

To change the shape of a connector message:

Right-cliông xã the connector.

At the bottom of the pop-up menu, select from the three options (Right-Angle, Straight, Curved).

Cliông chồng and drag the connector to change its shape.

Fragments

If one or more interactions size a loop, or require a condition to be met to end the interaction, encthua kém those interactions in a fragment shape:

Use the Loop fragment for a basic repeating interaction.

Use the Optional fragment for steps that are only performed if a certain condition is met.

Use the Alternative fragment shape for an if-then or if-then-else process or interaction. The fragment comes with two sections, which let you show the alternative sầu interaction. To add another condition, drag an Interaction operand onto the shape. 

Drag the fragment shape to lớn the interactions it relates to. Use the sizing handles on the fragment shape to lớn ensure it encloses all of the related interactions.

Double-clichồng in the title corner of the fragment shape lớn add a title or short description of the process enclosed by the fragment. Below the title corner, cliông chồng the prompt if you want to lớn enter the conditions that would end that process.

Activation


*


Start a sequence diagram

Near the upper right corner of the page, select More templates.

In the Gallery, scroll down to the UML Sequence row.

The first tác phẩm in the row represents a blank template plus the companion stencil. The other items in the row are sample diagrams that have sầu some shapes already drawn khổng lồ help you get started quickly.

Clichồng any item lớn see a larger previews.

When you find the diagram you want to use, click its Create button.

The new diagram, with the related stencil, opens in your browser.

Lifelines for actors & objects

Use an Actor lifeline shape for each participant, and an Object lifeline shape for each system component in your process.




Attach the beginning endpoint to the lifeline sending the message, then drag the head endpoint lớn the lifeline receiving the message.

Double-cliông chồng the message shape lớn create a text box, & type a name for the message.

Use a Message shape (a solid line) to lớn represent a request or the transmitting of information.

Xem thêm: Cách Vẽ Tranh Ngày 8 Tháng 3 Đơn Giản Mà Đẹp, Vẽ Tranh Đề Tài Về Ngày 8/3 Ngày Quốc Tế Phụ Nữ

Use a Return Message shape (a dashed line) to represent a response to a prior message.

Use a Self Message to represent a recursive hotline of an operation, or one method calling another method belonging khổng lồ the same object.

Use the Asynchronous Message shape to show when an action might not happen immediately.

To change the shape of a connector message:

Right-click the connector.

At the bottom of the pop-up thực đơn, select from the three options (Right-Angle, Straight, Curved).

Cliông xã & drag the connector to change its shape.

Fragments

If one or more interactions form a loop, or require a condition khổng lồ be met lớn over the interaction, enclose those interactions in a fragment shape:

Use the Loop fragment for a basic repeating interaction.

Use the Optional fragment for steps that are only performed if a certain condition is met.

Use the Alternative fragment shape for an if-then or if-then-else process or interaction. The fragment comes with two sections, which let you show the alternative sầu interaction. To add another condition, drag an Interaction operand onkhổng lồ the shape. 

Drag the fragment shape khổng lồ the interactions it relates lớn. Use the sizing handles on the fragment shape to ensure it encloses all of the related interactions.

Double-click in the title corner of the fragment shape khổng lồ add a title or short description of the process enclosed by the fragment. Below the title corner, clichồng the prompt if you want khổng lồ enter the conditions that would end that process.

Activation


To build a sequence diagram, use the UML Model template, which includes a mix of UML Sequence shapes. Drag shapes from the stencil onkhổng lồ the drawing canvas to lớn build the diagram.

Start a sequence diagram

Under Template Categories, cliông chồng Software & Database, & then cliông chồng UML Model Diagram.

In the Model Explorer tree view, right-cliông chồng the package in which you want lớn include the static structure diagram, point to lớn New, and cliông chồng Sequence Diagram.

A blank page appears, & the UML Sequence stencil becomes the top-most stencil. An inhỏ representing the diagram is added khổng lồ the tree view.


Note: If the tree view isn"t visible, point lớn View on the UML menu, and then cliông chồng Model Explorer.


Read on for more guidance about working with sequence diagrams.

Lifelines for actors & objects

Use an Object lifeline shape for each participant and system component in your process.

An object lifeline represents the existence of an object at a particular time. If the object is created or destroyed during the time period the diagram represents, the lifeline stops or starts at the appropriate point. An object"s destruction is marked with a large X.

Use a Lifeline shape

*
to show conditionality on an object lifeline.

Messages

Drag a Message shape onto the drawing page.

The message shape you choose depends upon the kind of message you want lớn sover (regular, asynchronous, procedure gọi, or return).

Glue the message endpoint without the arrowhead lớn a connection point

*
on the lifeline of the object sending the message.

Glue the message endpoint with the arrowhead khổng lồ a connection point on the lifeline of the object receiving the message.

Double-clichồng the message, & then type or choose the message name, stereotype, sequence expression, and flow kind.

For a flat message or procedure hotline, choose the operation you want the message khổng lồ generate. If the operation doesn"t exist, click New lớn create it.

For an asynchronous message, choose the signal you want the message to lớn generate. If no reception for the signal exists on the classifier that the object lifeline receiving the message is based on, click New khổng lồ create the reception.


Tip: To indicate a message from an object khổng lồ itself, glue the two endpoints on an arc-shaped Message shape to lớn two connection points on the same object lifeline.


Constraints

If one or more interactions require a condition to be met to lớn kết thúc the interaction, encthua those interactions in one of the constraint shapes:

A Constraint

*
is a specification for conditions and propositions that must be maintained as true for the system lớn be valid. Constraints are expressed as text within braces ( ) & may be written in a predefined language, such as Object Constraint Language (OCL) or in natural language.

Drag the control handle

*
at the center of the Constraint shape và glue it to a connection point on another element.

A 2-element Constraint

*
applies lớn two elements, such as two classes or two associations. The constraint is shown as a dashed arrow from one element lớn the other with the constraint string label in braces ( ).

An OR Constraint

*
indicates that any instance of a class may participate in only one association at one time. The constraint is shown as a dashed line connecting two or more associations, which must have a class in common. The line is labeled by the constraint string, OR, in braces ( ).

Activation


Place an Activation bar shape on a lifeline to show when và for how long that object or participant is active sầu in the process. Typically, there will be arrows going lớn and from an activation box khổng lồ demonstrate the flow of information.

Drag the endpoints of the Activation bar up or down to lớn make it the length that you want.