In Enterprise Studio all sorts of things can be copied for use in other parts of the tool. These not only include texts but also various aspects of models such as objects, relations, diagrams and views. Even entire models can be copied. In addition, objects and relations of open diagrams and views can be copied as images in different resolutions for use in other applications.
Different paste options are available when copying models and model components. Which option you use depends on what you want to achieve with copying. Which option is available at the time of copying depends on what you copy, where you copy, where you copy to, and in what situation.
You can copy model elements on two locations in the tool: in the model browser and between open diagrams and views (the drawing area). With that, a distinction can be made between copying within one model, between models within one model package, and between model packages. In addition, it can also make a difference whether you copy between diagrams or between views.
You cannot copy between models with different metamodels. It is only possible to copy between models that have the same metamodel.
On this page:
Copying in the model browser
Within one model
When copying within one model, it is not possible to copy individual objects and relations originating from the diagrams from one diagram to another. It is, however, possible to copy individual objects from views, not individual relations. Precondition for being able to copy the individual objects is that the model has a where these objects can be copied to. If this container is not available, it must be added first. You can also copy complete views and diagrams. When copying the physical elements are added to the model.
Between models within one model package
Within a model package, you can copy objects between models by copying (Ctrl+C) and pasting them (Ctrl+V), or by dragging them in the model browser from one model to the other. When copying between the models, the copied elements are placed as new elements at the target location in the model browser. There is no difference between diagram elements and view elements.
When copying between models, it is not possible to copy individual objects and relations of diagrams from one diagram to another. It is, however, possible to copy individual objects of views, not individual relations. You can also copy entire diagrams and views between the models within a model package.
Between model packages
When copying between model packages it is not possible to copy individual objects and relations of a diagram. It is possible to copy individual objects of views, relations can only be copied if the corresponding endpoints of the relation (the linked objects) are selected too for copying. Precondition for being able to copy individual objects of views is that the target model package has an appropriate container (scheme) where these objects can be copied to.When copying between model packages the copied elements are, as it were, imported in the target model package. The results of the copy operation are displayed in the Worksets pane that appears. In it, you can see what happened to the copied elements.
The names of the objects to be copied do not have to be unique, but it is recommended to take the name into account because when copying between model packages, matching on name is possible. When this happens, the tool checks for each object to be copied whether it already exists in the target model (of the same type) and has the same name. If so, no new object is created, instead, both objects are matched as much as possible.
When copying objects and models between model packages it is important that the metamodel information (types, profiles and attributes) of the object or model that is copied, is present in the model package where the data is copied to. When you copy from one model package to another, the tool checks whether the metamodel information belonging to the copied object or model is present in the model package you are copying to.
If the metamodel information is missing, you will be notified by the tool and you get the possibility to cancel copying. You can then first fix the metamodel information in the target model package before copying again.
When you copy a view from one model package to another, the view and the references in it are included in the copy and further only the objects where these references refer to. Other connections with the rest of the model are cut off in the copying operation: relations are not included unless they are also selected. The same applies to objects referenced from a profile property, like related work packages. If you want to copy these too, they should be included in the same copy operation. One way to do this is to not only select the view in the model browser, but also the desired folders with work packages, and then copy the whole. The references will remain intact.
Copying in two steps (first the work packages and then the view) will not retain the references: the copy function is not able to afterward divert these references to the work packages present in the target model package. Instead, it will break them.
Copying between open diagrams or views
Within one model
When copying between open diagrams or views (that is in the drawing area) within a single model, there is a difference in copying between diagrams and copying between views. Because a view only contains graphic representations of elements (see also Difference between diagrams and views), only the graphical representations of the elements are copied when copying between views. The model browser will not receive any additional elements. When copying between diagrams the physical elements are copied. A copied element is also added to the target diagram in the model browser.
Between models within one model package
When copying between models within one model package the copied elements are not only placed at the target location, they are also placed as new elements in the target model in the model browser. This only applies to elements from diagrams. Elements from views are only placed on the target view because in this case only the graphical representations of the elements are copied. The corresponding physical (semantic) elements are not copied in the model browser. This only occurs when copying in the model browser.
Between model packages
When copying between open diagrams or views from different model packages individual objects and relations can be copied. If you copy an individual relation without selecting the corresponding endpoints (the linked objects) selected, these endpoints are automatically copied too.
There is one exception: in a collaboration (BPMN), only individual pools (with or without content) can be copied, intermediate relations (message flows) can not. If you select these relations for copying anyway, you may not be able to copy anything at all.
When copying between model packages the copied elements are not only placed on the target diagram or target view, they are placed also as new elements in the target model package in the model browser. The copied elements are, as it were, imported into the target model package. The results of the copy operation are displayed in the Worksets pane that appears. In it you can see what happened to the copied elements.
Roughly a distinction is made between "regular" and "special" pasting. The tool shows this difference in the paste function that can be approached in several ways: through the ribbon, in the context menu of the element that is pasted, or by means of a shortcut.
Regular paste: click Home > Paste (> Paste) or press Ctrl+V.
Special paste: click Home > Paste > Paste Special or press Ctrl+Shift+V.
In case of special paste, a separate window pops up in which you select the desired paste action. Example:
Alternatively, you can copy elements by dragging and dropping in the model browser. In that case, you select the elements you want to copy and drag them to the desired location in the model browser.
The various paste possibilities are listed below together with the effects. When speaking about copying elements, we do not only mean individual objects, but also other components such as diagrams, views, and entire models.
Regular copy and paste
This is the standard way of copying. The selected elements are added as new elements to the location where they are copied to. Nothing special happens. Regular pasting does not use a separate window with paste options. However, it is possible to perform a regular paste from the special paste options window. In that case, click Paste as copies.
Copy and paste with matching on name
This way of copying only applies when copying between model packages. When copying, the copied elements are compared with the existing model elements in the package in which they are stuck. The elements are compared to each other in type and name. If an element of the same type and the same name as the copied element is found in the target model package, there is a match. In that case, the two elements are joined together. If there is no match, the copied element is added as a new element to the model package.
For this type of pasting, click Paste as objects, matching on name with existing object. This option is only available when copying entire models, views, or objects and relations from views. It does not apply to copying diagrams, and objects and relations from diagrams.
Some additional comments regarding this mode of copying:
- When copying, elements that contain elements, such as views and folders, are not matched. Only the individual elements contained within them such as objects and relationships are.
- When matching two elements (objects or relations), any values that are fixed to profile attributes of the existing element will be overwritten by the ones of the element that is copied.
Settings for automatically match on name
When you copy using the key combination or by dragging in the model browser, you can choose to perform the matching automatically. In that case, you do not need to choose this option explicitly when pasting. Elements will then automatically be matched on name if it is applicable.
To activate it, select the Try to match copied objects with existing objects check box at the Enterprise Studio advanced options.
Copying objects and relations in different resolutions
The objects and relations that are shown in the diagrams and views, can be copied for use in other applications. Additionally, you can copy them in different resolutions, so you have the possibility to use the images in high quality.
To copy drawn objects and relations, select the desired elements in the open diagram or view and press the key combination that yields the desired resolution. Below are the possible key combinations for copying in different resolutions. The higher the resolution, the higher the quality of the image.
96 dpi (default resolution)
A copied image can be pasted directly but is also available as file "clipboard.png" in the temporary files folder (C:\Documents and Settings\path\Local Settings\Temp).
ArchiMate® is a registered trademark of The Open Group.