First, tool installation
1.AmaterasUML Offline Installation
Download amaterasuml_1.3.4.zip, such as address: Http://iij.dl.osdn.jp/amateras/56447/AmaterasUML_1.3.4.zip
Extract 3 jar packages into the Eclipse\plugins directory (e.g., G:\Program\ADT\eclipse\plugins)
2.GET Online Installation
->eclipse-help-install New Software
Input Address: http://download.eclipse.org/tools/gef/updates-pre-3_8/releases/
Select the latest version 3.72, tick next. Can
OK, restart Eclipse can be used, FQ can hang VPN, no more say
Ii. use of tools (continuous summary)
1. Right-click on a project that requires UML->new->other-> this time AMATERASUML has four options to choose
2. Select Class Diagram here to see the relationship between classes, so next, named, generates a. cld file
3. Drag the required class into the. CLD to view
Third, the basic knowledge points involved
The relationship between classes and classes
There are 6 total relationships here:
Dependency(Dependency): The representation of a method in Class A uses Class B, which is an accidental, temporary, very weak
Such as: people need to screw the screwdriver with the use of this class, that is, temporarily used in the method screwdriver class
[code performance] Public class person{ 2. /** */ 3. Public void Screw (screwdriver screwdriver) { 4. Screwdriver.screw (); 5. } 6.}
Association( Association): expressed as Class A takes class B as an attribute or global variable, visible is long-term, strong coupling
Code embodies
1 Public classa{2 Private b b;3 PublicA (b b) {4 This. B =b; 5 }6 Public voidf () {7 b.work ();8 } 9}
Generalization(generalization): Represents an inheritance relationship, such as the inheritance of classes and classes, and the inheritance of interfaces and interfaces
Realization(Implementation): implementing Interfaces
Aggregation(Aggregation): First aggregation is an association, a company has n employees, then the relationship between employees and the company is aggregation
Composite(Combination): The combination is also an association relationship, where people have noses, eyes, ears, organs, and human relations are combinations. Obviously, the coupling of the combination is higher, imagine the company leaving an employee and a person losing an arm!
Eclipse UML Plugin--AMATERASUML