Creating Packages

See Also

You can create a new UML Modeling package in a project from the Projects window.

While creating a package, if you want, you can also create a scoped diagram within the package. A package used in this way can help you organize your diagrams and other modeling elements visibly within the Projects window. Any type of UML diagram can be scoped to a package. Packages can be used at different levels: A diagram can contain a package, and a package can contained a scoped diagram.

To create a new package from the Projects window:

  1. In the Projects window, select and expand a project node to display its Model node.
  2. Right-click the Model node and choose Add > Package.
    The IDE opens the New - Create Package wizard.
  3. In the Name field, type a name for the new package.
  4. In the Namespace field, the default setting is the name of the project. You can choose any other namespace in the drop-down list for your new package's location.

    If you do not want to create a scoped diagram, click OK now to finish creating the package.

    To continue and create a scoped diagram within the new package:

  5. Select the Create Scoped Diagram checkbox.
    The IDE enables the Diagram Name and Diagram Type fields.
  6. Name the new scoped diagram.
  7. Select the type of diagram.
  8. Click OK.
    The IDE adds the new package to the Projects window under the Model node. If you created a scoped diagram for the package, the IDE now creates the diagram as well. Expand the new package node in the Projects window to display the new scoped diagram.

To create a new package from the Diagram editor:

  1. In the Diagram editor, display the diagram to which you want to add a package.
    The appropriate Modeling Palette window is displayed.
  2. In the Modeling Palette, click the Package icon Package icon.
  3. In the Diagram editor background, click where you want the package element.
    The IDE places a new package there.
  4. Click background locations in the Diagram editor until you have placed all the new packages you want.
    The IDE places a new package wherever you click.
  5. To stop replicating package elements and return the cursor to pointer mode, right-click.
See Also
Working With Packages

Legal Notices