UseCase, Class, Sequence, Collaboration, State Chart, Activity, Component, and Deployment Diagrams are used in UML. Describe each of the eight (8) main diagrams used in UML.
Answer:
Use Case Diagrams depict:
- Use cases. A use case describes a sequence of actions that provide something of measurable value to an actor and is drawn as a horizontal ellipse.
- Actors. An actor is a person, organization, or external system that plays a role in one or more interactions with your system. Actors are drawn as stick figures.
- Associations. Associations between actors and use cases are indicated in use case diagrams by solid lines. An association exists whenever an actor is involved with an interaction described by a use case. Associations are modeled as lines connecting use cases and actors to one another, with an optional arrowhead on one end of the line. The arrowhead is often used to indicating the direction of the initial invocation of the relationship or to indicate the primary actor within the use case. The arrowheads are typically confused with data flow and as a result I avoid their use.
- System boundary boxes (optional). You can draw a rectangle around the use cases, called the system boundary box, to indicates the scope of your system. Anything within the box represents functionality that is in scope and anything outside the box is not. System boundary boxes are rarely used, although on occasion I have used them to identify which use cases will be delivered in each major release of a system. Figure 2 shows how this could be done.
- Packages (optional). Packages are UML constructs that enable you to organize model elements (such as use cases) into groups. Packages are depicted as file folders and can be used on any of the UML diagrams, including both use case diagrams and class diagrams. I use packages only when my diagrams become unwieldy, which generally implies they cannot be printed on a single page, to organize a large diagram into smaller ones. Figure 3 depicts how Figure 1 could be reorganized with packages.
(Ambler-1, 2006)The diagram-77 is extracted from
http://www.agilemodeling.com/artifacts/useCaseDiagram.htm to show System Use Case Diagram.

Diagram-77 - System Use Case Diagram
In software engineering, a
Class Diagram in the Unified Modeling Language (UML), is a type of static structure diagram that describes the structure of a system by showing the system's classes, their attributes, and the relationships between the classes.
(Wikipedia-1, 2009)UML 2 class diagrams are the mainstay of object-oriented analysis and design. UML 2 class diagrams show the classes of the system, their interrelationships (including inheritance, aggregation, and association), and the operations and attributes of the classes. Class diagrams are used for a wide variety of purposes, including both conceptual/domain modeling and detailed design modeling. Although I prefer to create class diagrams on whiteboards because simple tools are more inclusive most of the diagrams that I’ll show in this article are drawn using a software-based drawing tool so you may see the exact notation.
(Ambler-2, 2006)The diagram-78 is extract from
http://en.wikipedia.org/wiki/Class_diagram to show an example of Class Diagram.

Diagram-78 - Class Diagram
UML Sequence Diagrams model the flow of logic within your system in a visual manner, enabling you both to document and validate your logic, and are commonly used for both analysis and design purposes. Sequence diagrams are the most popular UML artifact for dynamic modeling, which focuses on identifying the behavior within your system. Other dynamic modeling techniques include activity diagramming, communication diagramming, timing diagramming, and interaction overview diagramming. Sequence diagrams, along with class diagrams and physical data models are in my opinion the most important design-level models for modern business application development.
(Ambler-3, 2006)A sequence diagram in Unified Modelling Language (UML) is a kind of interaction diagram that shows how processes operate with one another and in what order. It is a construct of a Message Sequence Chart. Sequence diagrams are sometimes called Event-trace diagrams, event scenarios, and timing diagrams.
(Wikipedia-2, 2009)The Diagram-79 is extracted from
http://en.wikipedia.org/wiki/File:Restaurant-UML-SEQ.gif to show an example of the Sequence Diagram.

Diagram-79 - Sequence Diagram
UML
Collaboration Diagrams / communication diagrams like UML sequence diagrams, are used to explore the dynamic nature of your software. Collaboration diagrams show the message flow between objects in an OO application, and also imply the basic associations (relationships) between classes. Collaboration diagrams are often used to:
- Provide a birds-eye view of a collection of collaborating objects, particularly within a real-time environment.
- Allocate functionality to classes by exploring the behavioral aspects of a system.
- Model the logic of the implementation of a complex operation, particularly one that interacts with a large number of other objects.
- Explore the roles that objects take within a system, as well as the different relationships they are involved with when in those roles.
(Ambler-4, 2009)The diagram-80 is to show the example of Collaboration Diagram. (from
http://www.agilemodeling.com/style/collaborationDiagram.htm)

Diagram-80 - Collaboration Diagram
UML state machine diagrams, formerly called
State Chart Diagrams in UML 1, depict the dynamic behavior of an entity based on its response to events, showing how the entity reacts to various events depending on the current state that it is in. Create a UML state machine diagram to explore the nature of a:
- Explore the complex behavior of a class, actor, subsystem, or component.
- Modeling real-time systems.
(Ambler-5, 2009)The Diagram-81 shows the example of State Chart Diagram extracted from
http://www.agilemodeling.com/style/stateChartDiagram.htm
Diagram-81 - State Chart Diagram
In UML, an
Activity Diagram is used to display the sequence of activities. Activity diagrams show the workflow from a start point to the finish point detailing the many decision paths that exist in the progression of events contained in the activity. They may be used to detail situations where parallel processing may occur in the execution of some activities. Activity diagrams are useful for business modeling where they are used for detailing the processes involved in business activities.
(Sparx, 2009)An Example of an activity diagram is shown in the below Diagram-82 extracted from http://www.sparxsystems.com.au/resources/uml2_tutorial/uml2_activitydiagram.html
Diagram-82- Activity Diagram
A
Component Diagram in the Unified Modeling Language, depicts how components are wired together to form larger components and or software systems.
(Wikipedia-3, 2009)The Diagram-83 is extracted from
http://en.wikipedia.org/wiki/Component_diagram and is to show an example of Component Diagram.

Diagram-83 - Component Diagram
A UML2
Deployment Diagram depicts a static view of the run-time configuration of processing nodes and the components that run on those nodes. In other words, deployment diagrams show the hardware for your system, the software that is installed on that hardware, and the middleware used to connect the disparate machines to one another. You want to create a deployment diagram for applications that are deployed to several machines, for example a point-of-sales application running on a thin-client network computer which interacts with several internal servers behind your corporate firewall or a customer service system deployed using a web services architecture such as Microsoft’s .NET. Deployment diagrams can also be created to explore the architecture of embedded systems, showing how the hardware and software components work together. In short, you may want to consider creating a deployment diagram for all but the most trivial of systems.
(Ambler-6, 2009)The Diagram-84 is used to demonstrate the example of Deployment Diagram and is extracted from
http://www.agilemodeling.com/artifacts/deploymentDiagram.htm

Diagram-84 - Deployment Diagram
Reference:1. Ambler Scott W. (2006). "UML 2 Use Case Diagrams". Ambysoft Inc., Retrieved from URL - http://www.agilemodeling.com/artifacts/useCaseDiagram.htm
2. Ambler Scott W. (2006). "UML 2 Class Diagrams". Ambysoft Inc., Retrieved from URL - http://www.agilemodeling.com/artifacts/classDiagram.htm
3. Ambler Scott W. (2006). "UML 2 Sequence Diagrams". Ambysoft Inc., Retrieved from URL - http://www.agilemodeling.com/artifacts/sequenceDiagram.htm
4. Ambler Scott W. (2006). "UML 2 Communication Diagramming Guidelines". Ambysoft Inc., Retrieved from URL - http://www.agilemodeling.com/style/collaborationDiagram.htm
5. Ambler Scott W. (2006). "UML 2 State Machine Diagramming Guidelines". Ambysoft Inc., Retrieved from URL - http://www.agilemodeling.com/style/stateChartDiagram.htm
6. Ambler Scott W. (2006). "UML 2 Deployment Diagrams". Ambysoft Inc., Retrieved from URL - http://www.agilemodeling.com/artifacts/deploymentDiagram.htm
7. Sparx (2009). "Sparx Systems - UML 2 Tutorial - Activity Diagram". Sparx Systems Pty Ltd, Retrieved from URL - http://www.sparxsystems.com.au/resources/uml2_tutorial/uml2_activitydiagram.html
8. Wikipedia-1 (2009). "Class Diagram". Wikipedia The Free Encyclopedia, Retrieved from URL - http://en.wikipedia.org/wiki/Class_diagram
9. Wikipedia-2 (2009). "Sequence diagram". Wikipedia The Free Encyclopedia, Retrieved from URL - http://en.wikipedia.org/wiki/Sequence_diagram
10. Wikipedia-3 (2009). "Component Diagram". Wikipedia The Free Encyclopedia, Retrieved from URL - http://en.wikipedia.org/wiki/Component_diagram