In software and systems engineering, a use case is a list of steps, typically defining interactions between a role (known in UML as an "actor") and a system, to achieve a goal. The actor can be a human or an external system.
In systems engineering, use cases are used at a higher level than within software engineering, often representing missions or stakeholder goals. The detailed requirements may then be captured in SysML or as contractual statements.
|Structural UML diagrams|
|Behavioral UML diagrams|
In 1986 Ivar Jacobson first formulated textual, structural and visual modeling techniques for specifying use cases. In 1992 his co-authored book helped to popularize the technique for capturing functional requirements, especially in software development. Originally he used the terms usage scenarios and usage case – the latter being a direct translation of his Swedish term användningsfall – but found that neither of these terms sounded natural in English, and eventually he settled on use case. Since then, others have contributed to improving this technique, notably including Alistair Cockburn. In 2011, Ivar Jacobson published an update to use cases called Use Case 2.0, the intention being to incorporate many of his practical experiences of applying use cases since its original inception.
Use case structure 
Martin Fowler 
- Title: "goal the use case is trying to satisfy":101
- Main Success Scenario: numbered list of steps:101
- Step: "a simple statement of the interaction between the actor and a system":101
- Extensions: separately numbered lists, one per Extension:101
- Extension: "a condition that results in different interactions from .. the main success scenario". An extension from main step 3 is numbered 3a, etc.:101
Alistair Cockburn 
Fully dressed use case structure 
Cockburn's Fully dressed use case template lists the following fields:
- Title: "an active-verb goal phrase that names the goal of the primary actor"
- Primary Actor
- Goal in Context
- Stakeholders and Interests
- Minimal Guarantees
- Success Guarantees
- Main Success Scenario
- Technology & Data Variations List
- Related Information.
In addition, Cockburn suggests using two devices to indicate the nature of each use case: icons for design scope and goal level.
Cockburn's approach has influenced other authors; for example, Alexander and Beus-Dukic generalize Cockburn's "Fully dressed use case" template from software to systems of all kinds, with the following fields differing from Cockburn:
- Variation scenarios "(maybe branching off from and maybe returning to the main scenario)"
- Exceptions "i.e. exception events and their exception-handling scenarios"
Casual use case structure 
Cockburn recognizes that projects may not always need detailed "fully dressed" use cases. He describes a Casual use case with the fields:
- Title (goal)
- Primary Actor
- (Story): the body of the use case is simply a paragraph or two of text, informally describing what happens.
Design scope icon 
Cockburn suggests annotating each use case with a symbol to show the "Design Scope", which may be black-box (internal detail is hidden) or white-box (internal detail is shown). Five symbols are available:
- Organization (black-box), a filled icon of a house
- Organization (white-box), an unfilled icon of a house
- System (black-box), a filled icon of a box
- System (white-box), an unfilled icon of a box
- Component, an icon of a screw or bolt.
Other authors sometimes call use cases at Organization level "Business use cases".
Goal level icon 
- Very high summary, an icon of a cloud
- Summary, an icon of a flying kite
- User-goal, an icon of waves at sea
- Subfunction, an icon of a fish
- Too low, an icon of a seabed clam-shell.
A use case defines the interactions between external actors and the system under consideration to accomplish a goal. Actors must be able to make decisions, but need not be human: "An actor might be a person, a company or organization, a computer program, or a computer system — hardware, software, or both." Actors are always stakeholders, but many stakeholders are not actors, since they "never interact directly with the system, even though they have the right to care how the system behaves." For example, "the owners of the system, the company's board of directors, and regulatory bodies such as the Internal Revenue Service and the Department of Insurance" could all be stakeholders but are unlikely to be actors.
Similarly, a person using a system may be represented as different actors because he is playing different roles. For example, user "Joe" could be playing the role of a Customer when using an Automated Teller Machine to withdraw cash from his own account, or playing the role of a Bank Teller when using the system to restock the cash drawer on behalf of the bank.
Actors are often working on behalf of someone else. Cockburn writes that "These days I write 'sales rep for the customer' or 'clerk for the marketing department' to capture that the user of the system is acting for someone else." This tells the project that the "user interface and security clearances" should be designed for the sales rep and clerk, but that the customer and marketing department are the roles concerned about the results.
A stakeholder may play both an active and an inactive role: for example, a Consumer is both a "mass-market purchaser" (not interacting with the system) and a User (an actor, actively interacting with the purchased product). In turn, a User is both a "normal operator" (an actor using the system for its intended purpose) and a "functional beneficiary" (a stakeholder who benefits from the use of the system). For example, when user "Joe" withdraws cash from his account, he is operating the Automated Teller Machine and obtaining a result on his own behalf.
Cockburn advises to look for actors among the stakeholders of a system, the primary and supporting (secondary) actors of a use case, the system under design (SuD) itself, and finally among the "internal actors", namely the components of the system under design.
Use case notation 
In the Unified Modeling Language, the relationships between all (or a set of) the use cases and actors are represented in a Use Case Diagram or diagrams, originally based upon Ivar Jacobson's Objectory notation. SysML, a UML profile, uses the same notation at the system block level.
Limitations of use cases include:
- Use cases are not well suited to capturing non-interaction based requirements of a system (such as algorithm or mathematical requirements) or non-functional requirements (such as platform, performance, timing, or safety-critical aspects). These are better specified declaratively elsewhere.
- Use case templates do not automatically ensure clarity. Clarity depends on the skill of the writer(s).
- Use cases are complex to write and to understand, for both end users and developers.
- As there are no fully standard definitions of use cases, each project must form its own interpretation.
- Some use case relationships, such as extends, are ambiguous in interpretation and can be difficult for stakeholders to understand.
- In Agile, simpler user stories are preferred to use cases.
- Use case developers often find it difficult to determine the level of user interface (UI) dependency to incorporate in a use case. While use case theory suggests that UI not be reflected in use cases, it can be awkward to abstract out this aspect of design, as it makes the use cases difficult to visualize. In software engineering, this difficulty is resolved by applying requirements traceability, for example with a traceability matrix. Another approach to associate UI elements with use cases, is to attach a UI design to each step in the use case. This is called a use case storyboard.
- Use cases can be over-emphasized. Bertrand Meyer discusses issues such as driving system design too literally from use cases, and using use cases to the exclusion of other potentially valuable requirements analysis techniques.
- Use cases are a starting point for test design,  but since each test needs its own success criteria, use cases may need to be modified to provide separate postconditions for each path.
See also 
- Jacobson et al, 1992.
- "Alistair Cockburn, "Use cases, ten years later"". Alistair.cockburn.us. Retrieved 2013-04-17.
- "Business Analysis Conference Europe 2011 - 26-28 September 2011, London, UK". Irmuk.co.uk. Retrieved 2013-04-17.
- Fowler, 2004.
- Cockburn, 2001
- Cockburn, 2001. Page 120.
- Cockburn, 2001. Inside rear cover. Field "Use Case Title".
- Alexander and Beus-Dukic, 2009. Page 121
- Cockburn, 2001. Inside front cover. Icons "Design Scope".
- Suzanne Robertson. Scenarios in Requirements Discovery. Chapter 3 in Alexander and Maiden, 2004. Pages 39-59.
- Cockburn, 2001. Inside front cover. Icons "Goal Level".
- Cockburn, 2001. Page 53.
- Cockburn, 2001. Page 55.
- Alexander and Beus-Dukic, 2009. Page 39.
- Meyer, 2000. (page needed)
- Armour and Miller, 2000. (page needed)
- Denney, 2005. (page needed)
- Alexander, Ian, and Beus-Dukic, Ljerka. Discovering Requirements: How to Specify Products and Services. Wiley, 2009.
- Alexander, Ian, and Maiden, Neil. Scenarios, Stories, Use Cases. Wiley 2004.
- Armour, Frank, and Granville Miller. Advanced Use Case Modeling: Software Systems. Addison-Wesley, 2000.
- Cockburn, Alistair. Writing Effective Use Cases. Addison-Wesley, 2001.
- Denney, Richard. Succeeding with Use Cases: Working Smart to Deliver Quality. Addison-Wesley, 2005.
- Fowler, Martin. UML Distilled (Third Edition). Addison-Wesley, 2004.
- Jacobson Ivar, Christerson M., Jonsson P., Övergaard G., Object-Oriented Software Engineering - A Use Case Driven Approach, Addison-Wesley, 1992.
- Jacobson Ivar, Spence I., Bittner K. Use Case 2.0: The Guide to Succeeding with Use Cases, IJI SA, 2011.
- Meyer, Bertrand. Object Oriented Software Construction. (2nd edition). Prentice Hall, 2000.
- Schneider, Geri and Winters, Jason P. Applying Use Cases 2nd Edition: A Practical Guide.Addison-Wesley, 2001.
- Use Cases (Usability.gov)
- Basic Use Case Template by Alistair Cockburn
- Application of use cases for stakeholder analysis "Project Icarus: Stakeholder Scenarios for an Interstellar Exploration Program", JBIS, 64, 224-233
- "An Academic Survey on the Role of Use Cases in the UML"