Basic concepts of UML Models

Source: Internet
Author: User
ArticleDirectory
    • 1.1 UML
    • 1.1.1 structured transactions.
    • 1.1.2 action
    • 1.1.3 group things
    • 1.1.4 comment on things
    • 1.1.5 relationships in UML
    • 1.1.6 diagram in UML
Basic concepts of UML Models

1 UML building blocks

There are three basic building blocks for UML:
1. Things)
2. relationship (Relationships)
3. diagrams)
Things are an important part of UML. Links closely link things. A graph is a group of many related things.

1.1 UML

There are always types of things in UML:

1. Structural things)
2. Behavioral things)
3. group things)
4. annotational things)
These things are the most basic object-oriented building blocks in the UML model. They belong to the most static part in the model and represent conceptual or physical elements.

1.1.1 structured transactions.

There are a total of seven structured things. Class describes a set of objects with the same attributes, methods, relationships, and semantics. A class implements one or more interfaces. In UML, a class is drawn as a rectangle type, usually including its name, attributes, and methods.

Window
Origin size
Open ()
Close ()
Move ()
Display ()


 

 

 

Figure 1-Class 1
Interface refers to a set of operations that a class or component provides for a specific service. Therefore, an interface describes the externally visible actions of a class or component. An interface can implement all the actions of a class or component, or it can only implement a part. The interface is drawn into a circle and its name in UML.


Figure 1-2 Interface

The third type is collaboration, which defines interactive operations. Some roles work with other elements and provide cooperative actions, which are larger than the total number of elements. Therefore, collaboration is structured, actionized, and dimensional. A given class may be part of several collaborations. These collaborations represent the implementation of the system model. In UML, the collaboration is represented by an elliptic drawn by a dotted line and its name.


Figure 1-3 collaboration

The fourth type is use case. Use Case describes a series of actions that the system executes on a specific role and generate a value worth noting. In the model, use case is usually used to organize action things. Use Case is implemented through collaboration. In UML, use case is drawn as a solid-line elliptic, and usually has its name.

 

Figure 1-4 Use Case

The fifth type is the active class, which has one or more processes or threads. The activity class is very similar to the class, but its object represents the behavior of the element and other elements exist at the same time. In UML, the draw method and class of the activity class are the same, but the border uses coarse lines.

Eventmanager
Suspend ()
Flush ()

Figure 1-5 activity types

Component is a physical or replaceable system part that implements an interface set. In a system, you may encounter different types of components, such as COM + or Java Beans. Components are represented in the following diagram in UML:

Figure 1-6 Component 7 is a node. A node is a physical element that exists at runtime and represents a computing resource, it usually occupies some memory and has processing capability. A component set is generally located at one node, but may be transferred from one node to another. The knots are commonly expressed in the following figure:
Figure 1-7 nodes

Class, interface, collaboration, use case, Activity Class, component, and node are the most basic structured things used in the UML model. The system also contains the change bodies of these seven basic elements, such as roles, signals (a type), processes and threads (an activity class), and applications.Program, Document, file, library, table (a component ).

1.1.2 action

Dynamic things are dynamic parts of the UML model. They are model verbs that represent temporal and spatial actions. There are two main actions in total.
The first is ineraction, which is an action composed of a group of objects in a specific context for a specific purpose. Each operation of an object in interaction must be listed in detail, including the message, action order (action generated by the message), and connection (connection between objects ). In UML, messages are drawn as straight lines with arrows, usually with the operation name.

Figure 1-8 messages
The second is the state machine, which is composed of the States of a series of objects. In UML, the status is:
 
Pattern 1-9 Status

Interaction and state machine are the two most basic dynamic thing elements in the UML model. They are usually connected with other structural elements, main classes, and objects.

1.1.3 group things

A group object is a part of the UML model. It can be regarded as a box in which the model can be decomposed. There is only one group thing in total, called a package ).
A package is a mechanism for grouping organized elements. Structured, action, and even other grouped items can all be placed in a package. Unlike components (in runtime), packages are purely conceptual and only exist in the development stage. Use an example to indicate a package in UML:


Figure 1-10 packages

1.1.4 comment on things

Annotation is the interpretation part of the UML model. Use an example in UML:

Figure 1-11 comment

1.1.5 relationships in UML

UML has four relationships:
1. Dependency)
(Figure 1-12 dependencies)

2. Association)
(Figure 1-13 join)

3. Generalization)
(Figure 1-14 is generalized)
4. Implementation (realuzation)
(Figure 1-15)

1.1.6 diagram in UML

1, Class Figure (Class digoal)
2, Object graph (Class digoal)
3, Use case diagram (Use Case digoal)
4, Sequence diagram (Sequence digoal)
5, Collaboration diagram (Collaboration digoal)
6, Status chart (Statechart dichart)
7Activity diagram (Activity digoal)
8, Component diagram (Compomnent dimo-)
9, Distribution chart (Deployment dimo-)

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.