Package (UML)
Encyclopedia
A package in the Unified Modeling Language
Unified Modeling Language
Unified Modeling Language is a standardized general-purpose modeling language in the field of object-oriented software engineering. The standard is managed, and was created, by the Object Management Group...

 is used "to group elements, and to provide a namespace for the grouped elements". A package may contain other packages, thus providing for a hierarchical organization of packages.

Pretty much all UML elements can be grouped into packages. Thus, classes, objects, use case
Use case
In software engineering and systems engineering, a use case is a description of steps or actions between a user and a software system which leads the user towards something useful...

s, components
Component (UML)
A component in the Unified Modeling Language "represents a modular part of a system, that encapsulates its content and whose manifestation is replaceable within its environment. A component defines its behavior in terms of provided and required interfaces".A component may be replaced by another if...

, nodes
Node (UML)
A node In the Unified Modeling Language is a computational resource upon which UML artifacts may be deployed for execution.There are two types of nodes: device nodes and execution environments....

, node instances etc. can all be organized as packages, thus enabling a manageable organization of the myriad elements that a real-world UML model entails.

Usage

When organizing functional models (use case models, workflow models etc.), use packages to model the real-world modular structure of the system being modeled. When organizing source code, use packages to represent the different layers of the source code. For instance:
  • presentation layer
    Presentation logic
    In software development, presentation logic is concerned with how business objects are displayed to users of the software, eg the choice between a pop-up screen and a drop-down menu...

  • controller layer
  • data access layer
    Data access layer
    A data access layer is a layer of a computer program which provides simplified access to data stored in persistent storage of some kind, such as an entity-relational database....

  • integration layer
  • business services layer


When organizing component models, use packages to group the components according to ownership and/or reuse possibilities. For instance:
  • commercial-off-the-shelf products
    Commercial off-the-shelf
    In the United States, Commercially available Off-The-Shelf is a Federal Acquisition Regulation term defining a nondevelopmental item of supply that is both commercial and sold in substantial quantities in the commercial marketplace, and that can be procured or utilized under government contract...

  • open-source framework components
  • custom-built framework components
  • custom-built application components


When organizing deployment models, use packages to represent the different types of deployment environments that you will be modeling. For instance:
  • production environment
  • pre-production environment
  • integration test environment
  • system test environment
  • development environment
    Development environment
    In hosted software development, a development environment refers to a server tier designated to a specific stage in a release process....

The source of this article is wikipedia, the free encyclopedia.  The text of this article is licensed under the GFDL.
 
x
OK