Package Diagram
- Tags
- modelling
A UML diagram showing the structure of packages.
\begin{figure}
\centering
\begin{tikzpicture}
\begin{umlpackage}{java/util}
\begin{umlpackage}{java/util/jar}
\end{umlpackage}
\begin{umlpackage}[right=of java/util/jar]{ArrayList}
\end{umlpackage}
\begin{umlpackage}[below=of ArrayList]{LinkedList}
\end{umlpackage}
\end{umlpackage}
\end{tikzpicture}
\caption{Example package diagram.}
\end{figure}
Constructs uml
The package construct is visualised as a [see page 10, folder] used to group logically related source code. It doesn't show instances, only classes.
You can think of packages of namespaces used to isolate functionality to local modules and prevent name clashes.
\begin{figure}
\centering
\begin{tikzpicture}
\begin{umlpackage}{java/util}
\end{umlpackage}
\end{tikzpicture}
\caption{Example package.}
\end{figure}
You can tag a package with <<subsystem>>
(or suffix its name with a hierarchy
label) to indicate it describes physically related compiled code (not exactly
representative of how it is structured). For example you can have a utility
subsystem with zip-utility subsystem and ps2pdf
or pdf2ps
modules.
Import and Access Tags
Import [see page 11, tags] can be attached to associations between packages to indicate one package imports a whole package or specific elements within the package. Access tags are essentially the same.