A package is a grouping of model elements which means that a package can contain model elements of different kinds, including other packages to create hierarchies. A package defines a namespace for its contents using for various purposes.
Package Diagram at a Glance
Package diagram is used to simplify complex class diagrams, you can group classes into packages. A package is a collection of logically related UML elements.
The diagram below is a business model in which the classes are grouped into packages:
- Packages appear as rectangles with small tabs at the top.
- The package name is on the tab or inside the rectangle.
- The dotted arrows are dependencies.
- One package depends on another if changes in the other could possibly force changes in the first.
Basic Concepts of Package Diagram
Package diagram follows hierarchal structure of nested packages. Atomic module for nested package are usually class diagrams. There are few constraints while using package diagrams, they are as follows.
- Package name should not be the same for a system, however classes inside different packages could have the same name.
- Packages can include whole diagrams, name of components alone or no components at all.
- Fully qualified name of a package has the following syntax.
Packages can be represented by the notations with some examples shown below:
Package Diagram — Dependency Notation
There are two sub-types involved in dependency. They are <<import>> & <<access>>. Though there are two stereotypes users can use their own stereotype to represent the type of dependency between two packages.
Key Elements of Package Diagram
Packages are used to organize a large set of model elements:
- Visibility
- Import
- Access
When to Use Packages?
To create an overview of a large set of model elements
- To organize a large model
- To group related elements
- To separate namespaces
Visibility of Packages
Each contained element has a visibility relative to the containing package.
- A public element is visible to elements outside the package, denoted by ‘+’
- A protected element is visible only to elements within inheriting packages, denoted by ‘#’
- A private element is not visible at all to elements outside the package, denoted by ‘-’
- Same syntax for visibility of attributes and operations in classes
Import Relationship between Packages
The associations are owned by package X:
Import and Access
Inheritance
A package with a generalization to another package inherits public and protected elements that are owned or imported by the inherited package. Packages are shown in static diagrams two equivalent ways to show containment:
Subsystems
Subsystems are used for system decomposition that can be represented by the parts of a system: (Specification / Realization)
Subsystem Internal and External Aspects
A subsystem has a specification and a realization to represent the two views:
- An external view, showing the services provided by the subsystem
- An internal view, showing the realization of the subsystem
- There is a mapping between the two aspects
Modeling Tips of Subsystem
- Define a subsystem for each separate part of a large system
- Choose specification technique depending on factors like kind of system and kind of subsystem
- Realize each subsystem independently, using the specification as a requirements specification
Modeling Complex Grouping
A package diagram is often used to describe the hierarchical relationships (groupings) between packages and other packages or objects. A package represents a namespace.
Package Diagram Example — Layering Structure
Try it your Own and Have Fun with Visual Paradigm Online
Visual Paradigm online (FREE Express Edition)
- Free Package Diagram examples and templates editable in an online Package Diagram software: Visual Paradigm Online.
- Use the templates as a starting point to create your own Package Diagram.
It’s going to be ending of mine day, except before finish
I am reading this great piece of writing to increase
my experience.
I have read several good stuff here. Certainly worth
bookmarking for revisiting. I surprise how much effort you put to create any such
excellent informative website.
I like the valuable info you supply on your articles.
I will bookmark your blog and check once more here
regularly. I am quite sure I’ll learn plenty
of new stuff right right here! Best of luck for the next!
Greetings! Very useful advice within this article! It’s the little changes that make the most significant changes.
Thanks for sharing!
Hi to every body, it’s my first visit of this blog; this webpage carries remarkable and actually excellent data
designed for visitors.
I’m gone to inform my little brother, that he
should also pay a visit this weblog on regular basis to get updated from
newest news update.
I am regular reader, how are you everybody? This piece of writing posted at this site is truly fastidious.
If you wish for to take much from this paragraph then you
have to apply these techniques to your won web site.
Wow, superb blog layout! How long have you been blogging for?
you made blogging look easy. The overall look of your website is
magnificent, as well as the content!
This is really interesting, You’re a very skilled blogger.
I’ve joined your rss feed and look forward to seeking
more of your wonderful post. Also, I’ve shared your web
site in my social networks!
I do not even know how I ended up here, but I thought this post was great.
I do not know who you are but definitely you are going to a famous blogger
if you aren’t already 😉 Cheers!
Have you ever thought about adding a little bit more than just your
articles? I mean, what you say is fundamental and all. Nevertheless think
of if you added some great pictures or video clips to give your posts more,
„pop”! Your content is excellent but with images and video clips,
this blog could undeniably be one of the greatest in its field.
Awesome blog!
This is really attention-grabbing, You’re an excessively skilled blogger.
I have joined your rss feed and stay up for seeking
extra of your fantastic post. Additionally, I’ve shared
your site in my social networks
It’s nearly impossible to find experienced people on this topic, but
you sound like you know what you’re talking about! Thanks
Asking questions are in fact fastidious thing if you are
not understanding something completely, however this article presents fastidious
understanding even.
If some one wishes to be updated with most recent technologies afterward
he must be go to see this web site and be up to date all the time.
Have you ever considered about including a little bit more than just your articles?
I mean, what you say is valuable and everything.
However just imagine if you added some great photos or video clips to give your
posts more, „pop”! Your content is excellent but with images and video clips,
this site could certainly be one of the very best in its niche.
Fantastic blog!
Good info. Lucky me I ran across your blog by chance (stumbleupon).
I’ve saved as a favorite for later!
I’m extremely impressed with your writing skills
and also with the format on your blog. Is that
this a paid subject or did you customize it
your self? Either way stay up the nice high quality writing, it is rare
to look a great blog like this one these days..
I need to to thank you for this great read!!
I definitely loved every little bit of it. I have got you book marked to look at new things you post…
If you wish for to grow your know-how only keep visiting this website and
be updated with the newest information posted here.
Hi to every single one, it’s truly a fastidious for
me to visit this website, it includes important Information.
Thanks on your marvelous posting! I seriously enjoyed reading it, you’re a
great author.I will remember to bookmark your blog and will
come back in the foreseeable future. I want to encourage one to continue your great posts, have a nice afternoon!
Fantastic beat ! I would like to apprentice while you amend your website,
how can i subscribe for a blog site? The account aided me a
acceptable deal. I had been tiny bit acquainted of this your broadcast provided bright clear concept
Remarkable things here. I’m very glad to look your post.
Thanks a lot and I am having a look forward to contact
you. Will you kindly drop me a e-mail?
Simply wish to say your article is as astonishing. The clearness
in your post is just great and i could assume you’re an expert on this subject.
Well with your permission let me to grab your feed to keep up to date with forthcoming
post. Thanks a million and please continue the enjoyable work.
Thanks , I have recently been searching for info about this topic for a long time and yours is
the greatest I have found out so far. But, what in regards
to the bottom line? Are you certain concerning the
source?
Hello there, just became aware of your blog through Google, and found that it is truly informative.
I am gonna watch out for brussels. I will appreciate if you continue this in future.
Numerous people will be benefited from your writing. Cheers!
Great beat ! I would like to apprentice while you amend your web site,
how could i subscribe for a blog web site? The account helped me a acceptable deal.
I had been tiny bit acquainted of this your
broadcast provided bright clear idea
With havin so much content and articles do you ever run into
any problems of plagorism or copyright infringement?
My website has a lot of exclusive content I’ve either written myself or outsourced but it looks
like a lot of it is popping it up all over the internet without my permission. Do you
know any techniques to help prevent content from being stolen? I’d
definitely appreciate it.
Hi, I read your new stuff on a regular basis. Your humoristic style is awesome, keep doing what you’re doing!
Helpful info. Lucky me I discovered your site by accident, and I am stunned why this coincidence did
not came about earlier! I bookmarked it.
hello!,I love your writing so a lot! share we be in contact more
about your article on AOL? I need an expert in this space to resolve
my problem. Maybe that is you! Looking forward to look you.
Someone necessarily lend a hand to make critically posts I would state.
This is the very first time I frequented your web page and so far?
I surprised with the analysis you made to make this actual post extraordinary.
Great task!
Hey! Do you use Twitter? I’d like to follow you if that would be
ok. I’m definitely enjoying your blog and look forward to new posts.
Greetings! Very useful advice in this particular article!
It’s the little changes that make the greatest changes.
Thanks a lot for sharing!
This article will help the internet people for setting up new weblog or even a blog from start to end.
I am sure this post has touched all the internet visitors, its really really nice post on building
up new weblog.
Heya i am for the first time here. I found this board and I in finding It really helpful & it helped me out much.
I am hoping to provide something again and aid
others such as you helped me.
When I originally left a comment I appear to have clicked
on the -Notify me when new comments are added- checkbox and
from now on each time a comment is added I get four emails with
the same comment. Is there an easy method you can remove
me from that service? Thanks a lot!
magnificent issues altogether, you just received a new reader.
What could you suggest in regards to your submit that you simply made some
days ago? Any positive?
Its like you learn my mind! You appear to understand a lot about this,
like you wrote the e book in it or something. I feel that you could
do with a few % to force the message house a little bit,
however instead of that, that is excellent blog. An excellent read.
I will certainly be back.
I think this is one of the most vital info for me. And i’m glad reading your article.
But want to remark on few general things, The website style is perfect, the
articles is really nice : D. Good job, cheers
A person necessarily assist to make seriously posts I might state.
That is the very first time I frequented your web page and
to this point? I surprised with the research you
made to create this particular publish incredible.
Wonderful task!
Hi just wanted to give you a quick heads up and let you know a few of the images aren’t loading properly.
I’m not sure why but I think its a linking issue. I’ve tried it in two different internet
browsers and both show the same results.
I do not even know how I ended up here, but I thought this
post was great. I don’t know who you are but definitely you’re going to a famous blogger
if you are not already 😉 Cheers!
Fantastic web site. Plenty of useful info here.
I am sending it to several buddies ans also sharing in delicious.
And of course, thanks to your sweat!
Great info. Lucky me I came across your website by chance (stumbleupon).
I’ve book marked it for later!
Thanks for sharing your thoughts. I truly
appreciate your efforts and I am waiting for your next post thank you once again.
I’m extremely inspired with your writing talents as well as with the structure for your blog.
Is that this a paid topic or did you modify
it yourself? Anyway keep up the nice high quality writing, it is rare to look a great weblog like this one nowadays..
I am really thankful to the owner of this web page who has
shared this wonderful post at here.
Wow that was odd. I just wrote an incredibly long comment but after I clicked submit my comment didn’t show
up. Grrrr… well I’m not writing all that over again. Anyway, just wanted to say excellent blog!
Undeniably believe that which you said. Your favorite reason seemed to be on the web the simplest thing to be
aware of. I say to you, I certainly get annoyed while people consider worries that they
just do not know about. You managed to hit the nail upon the top and also defined out the whole thing
without having side effect , people could take a signal.
Will probably be back to get more. Thanks
What’s Taking place i’m new to this, I stumbled upon this I’ve discovered It positively helpful and it
has helped me out loads. I hope to contribute & help different customers like its helped me.
Good job.
What’s up to every one, it’s in fact a nice for me to visit this site, it consists of priceless Information.
WOW just what I was looking for. Came here by
searching for wild bounty
Hello it’s me, I am also visiting this site regularly, this site is
truly fastidious and the viewers are really sharing good
thoughts.
Very energetic article, I loved that a lot. Will there be
a part 2?
Thanks , I have just been looking for information about this topic
for a long time and yours is the best I’ve discovered till now.
But, what concerning the conclusion? Are you certain about the source?