Chapter 1. Requirement Analysis

Table of Contents

Use-Cases

Use-Cases

Use Case: Play Music from the Catalog

Precondition

The player is up and running and has retrieved its music database.

Main Flow

The user presses the play button.

Alternate Flow

The user selects a title in the list and presses the play button.

Alternate Flow

The user selects some criteria in the artist, composer, album or genre list and presses the play button.

Alternate Flow

The user selects some titles and presses the play button.

Postcondition

The player plays the selected music once or for ever, depending on the setup of the shuffle and repeat toggle buttons.

Exceptional Flow

One or more music files cannot be retrieved. A warning is shown. After confirming the warning, the player skips the broken file and tries the next one or stops playing when the the corresponding button in the warning message is shown.

Use Case: Play Music from Playlists

Precondition

The player is up and running, has retrieved its music database and the playlists. The playlists have to be listed in the playlist and media list.

Main Flow

The user clicks on the playlist name in the media list. The playlist is displayed like any other selection in the music list and the player starts playing the first title or if shuffle is activated.the first title the shuffle function chooses.

Postcondition

The player plays the selected music once or for ever, depending on the setup of the shuffle and repeat toggle buttons.

Exceptional Flow

One or more files cannot be opened. The player displays a warning message were the uses can try to play the rest of the files or stop playing the list.

Use Case: Play Streams

Precondition

The player is up and running, has retrieved its music database and the registered streams. The streams have to be listed in the media list.

Main Flow

The user clicks on the stream, the player connects to the remote host, starts reading the stream and plays the tune.

Alternate Flow

The user clicks on the stream, the player connects to the remote host, the host requests a login. If the user enters a valid login and password, the player retrieves the stram and plays the tune. If the login is wrong, the login dialog is displayed again.

Alternate Flow

The user clicks on the stream, the player connects to the remote host, the host requests a login. The user press the don't play button.

Postcondition

If a stream is received, a tune is played

Exceptional Flow

The host does not exist, or the URL is not valid. Then the program displays an error message about the failure.

Use Case: Compose Playlists

Precondition

The player is up and running and has retrieved its music database.

Main Flow

The user selects some entries in the music database and selects the new playlist menu option. After that a name for the new list have to be entered in the media list.

Alternate Flow

The user selects some entries in the music database and selects the new playlist menu option. After that a name for the new list have to be entered in the media list. If a name is entered which already is used for another list, a number is appended to the name automatically.

Postcondition

A new playlist entry is sitting in the media list and a corresponding media list info is wirtten to the database.

Use Case: Delete Playlists

Precondition

The player is up and running and has retrieved its music database.

Main Flow

The user selects one or more playlists and activates the delete function for playlists, which could be available through a context menu. The selected playlists get unlisted from the playlist list and marked for deletion in the database. This allows later undo and no dialog is needed.

Alternate Flow

The user selects one or more playlists where one list is playing and activates the delete function for playlists, which could be available through a context menu. The player marks all list for deletion, except the playing list and asks the user if the list should be deleted right now and the playing stopped or if he/she want to continue playing the list.

Postcondition

One or more lists are marked for deletion and no longer present in the playlist list.

Use Case: Add Music to Playlists

Precondition

The player is up and running and has retrieved its music database.

Main Flow

The user selects a music in the music list and drags the selection to the playlist where the items shall be added.

Postcondition

New music titles have been added to a playlist. The playlist changes are written to the music database.

Exceptional Flow

The user selects serveral music titles and tries to trigger the add function, which is not present when no list is selected.

Use Case: Remove Music from Playlists

Precondition

The player is up and running and has retrieved its music database.

Main Flow

The user selects a playlist, which is then displayed as a selection in the music titles view. Then the user selects one or more files and triggers the delete function. The entires get deletion marks (for undo) and get unlisted from the playlist.

Postcondition

One or more entries in the playlist are marked for deletion. On program exist (or start) these entries are removed.

Use Case: Reorder Music in Playlists

Precondition

The player is up and running and has retrieved its music database.

Main Flow

The user selects a playlist, which is then displayed as a selection in the music titles view. Now the user can drp titles up and down, and give them a new order.

Postcondition

The order of the playlist elements have been changed and these changes are comitted to the database.

Use Case: Add Music to the Database

Precondition

Main Flow

Alternate Flow

Postcondition

Exceptional Flow

Use Case: Remove Music from the Database

Precondition

The player is up and running and has retrieved its music database.

Main Flow

The user selects one or more titles from the music titles view and triggers the delete function. All selected titles get removed from the list and a deletion mark in the database. The files itself will not be deleted. All playlists using the selected titles get their entries marked for deletion too.

Alternate Flow

The user selects one or more titles from the music titles view and triggers the purge function. All selected titles get removed from the list and a purge mark in the database. The playlists referencing these titles get deletion marks too. On program exit or restart, the entries are removed and the files are deleted (moved to trash).

Postcondition

All changes are comitted to database.

Use Case: Add Streams

Precondition

Main Flow

Alternate Flow

Postcondition

Exceptional Flow

Use Case: Remove Streams

Precondition

Main Flow

Alternate Flow

Postcondition

Exceptional Flow

Use Case: Change listed Attributes

Precondition

Main Flow

Alternate Flow

Postcondition

Exceptional Flow

Use Case: Change all Attributes

Precondition

Main Flow

Alternate Flow

Postcondition

Exceptional Flow