MagicDraw 18.5 Documentation
- Created by Agnė Palenskienė on Apr 28, 2017
You must lock a part of the model you are going to edit so that other users could not edit it at the same time. Locking is allowed, if that part of the model is not locked by another user, because the same item can be locked by a single user at a time.
The following table explains what you can edit after you lock a single element, single diagram, diagram with elements, and so on.
When you lock... | You can... |
---|---|
Element | Edit element specification properties (in the Specification window) |
Diagram | Edit:
|
Diagram with elements | Edit:
|
Symbol styles | Edit properties of symbol styles (in the Project Options dialog) |
Project usages |
|
Representation of locked elements
In the Containment tree, names of elements are presented in two colors:
- Locked elements are presented in black, meaning they are editable.
- Unlocked elements are presented in grey, meaning they are not editable.
Locking elements and diagrams
Elements and diagrams can be locked by using the commands from their shortcut menu.
Elements can also be locked by clicking the Lock element for Edit button on their Specification window.
The following table provides suggestions on what locking commands to use for different purposes.
If you need to edit... | Do the following |
---|---|
Specification properties of a single element |
OR
|
Specification properties of both an element and the elements it contains (owns) Let's say a project has a Package Analysis, which contains two inner Packages Lock the Package Analysis recursively to edit all the elements in this Package. |
|
At least one of the following:
|
OR
|
At least one of the following:
|
OR
|
At least one of the following:
|
|
Locking symbol styles
Symbol styles can be locked via the Lock View tab or the Project Options dialog.
To lock symbol styles via the Lock View tab
In the Lock View tab on the Model Browser, expand Project Options.
Where is the Lock View tab?It is the last tab on the Model Browser. If the tab is closed, you can simply open. For this, select Collaborate > View Locked Elements.- Right-click Symbol Styles and from the shortcut menu select Lock Symbol Styles for Edit.
To lock symbol styles via the Project Options dialog
- Do either:
- Select Options > Project.
In the Lock View tab on the Model Browser, right-click Project Options and from the shortcut menu, select Symbol Styles.
Where is the Lock View tab?It is the last tab on the Model Browser. If the tab is closed, you can simply open. For this, select Collaborate > View Locked Elements.
- In the Project Options dialog, click the Lock Symbol Styles for Edit button.
As a result, symbol styles become editable. Plus, the Make Default button (1) in all Symbol Properties dialogs and the Set Selected Symbol Style as Default button (2) on all the diagram toolbars become available.
Locking project usages
To lock a used project
Do either:
- In the Lock View tab on the Model Browser, right-click Project Structure and select Options.
- From the Options menu, select Project Usages.
2. In the opened Used Projects dialog, select a used project on the left side of the dialog and click the Lock button.
As a result, you can import this used project as a package to the main project, stop using it, or change its version.
Locking for reverse engineering
To reverse a code to the model that was already reversed, you need to lock elements that store code engineering information.
To lock elements for reverse engineering
- In the Code engineering sets branch, select a code engineering set or code engineering element you want to reverse.
- On the selected items shortcut menu, click Reverse. The Reverse Options dialog opens.
- In the Reverse Options dialog, set required options and click OK.
- The Lock Elements dialog opens. Select elements you want to lock and click OK.
- Depending on options you have selected in the Reverse Options dialog, you may need to perform some more steps. Please follow instructions provided on your screen.
Locking the project structure
There is an additional model integrity protection for a collaborative environment. All project structure modifications can only be done by a single person at the same time. To prevent simultaneous structure modification, project structure locking is realized.
If you are in a collaborative environment and working simultaneously on the same project, the following operations cannot be performed in parallel:
Modifying shared packages. Adding and removing shared packages are now controlled by the project structure lock.
Importing new project features. Some plugins may install additional features, such as specific options or code engineering abilities. An opened project structure is locked automatically, and this project cannot be opened by other users.
Upgrading project versions. The project structure is locked when the project is migrated from an earlier version to the later version (for example, from version 17.0 to 17.0.1). While one user is upgrading project version, the project is in read-only mode for other users until the first user commits this project.
The project structure is automatically locked to ensure the correct model integrity when you perform one of these operations. While the project structure is locked other users may continue getting error messages which may prevent to work with the model. The project structure is unlocked automatically when the project is committed. Alternatively, you can unlock the structure manually.
The project structure can be locked via the Lock View tab or the Project Properties dialog.
To lock a project structure via the Lock View tab
In the Lock View tab on the Model Browser, rigt-click Project Structure and select Lock Project Structure.
Where is the Lock View tab?It is the last tab on the Model Browser. If the tab is closed, you can simply open. For this, select Collaborate > View Locked Elements.
To lock a project structure via the Project Properties dialog
- From the File menu, select Project Properties. The Project Properties dialog opens.
- In the General tab, click the Lock Project Structure button.
- No labels