Skip to content

Latest commit

 

History

History
267 lines (209 loc) · 13.7 KB

REQ_s273797.md

File metadata and controls

267 lines (209 loc) · 13.7 KB

Official Requirements Document - EZGaz

Author: Gabriele Filaferro

Date: 27/03/2020

Contents

Abstract

A guy from Genoa moves to Turin to study at Politecnico. Loving to go around the city he brings his motorcycle with him. After some days in Turin he needs to fill up the tank of his bike but, not being used to the new city, he doesn't know where to find a gas station. Being from Genoa, he wants to spend as little as possible for gas money, so he can't use some basic maps application not providing prices for fuel. Being a Computer Engineer student he decides to create an app to help him and all other peole.

In order to use the app a user needs to register through an external IDP (Google, Facebook, GitHub, etc...). The app is based on crowdsourcing, so every user needs to be an active part in the system. A user can see all the gas stations in the app. A user can add the prices for a gas station accompained by a picture of the pricing table. A user can see the an average of pricetables posted by other users. In a single day a user is limited to know info about price of X gas stations at maximum, where X is the number of gas stations s/he updated in the last 3 days. This is based on the assumption that fuel prices usually don't change overnight.

Stakeholders

Name Description
Developper Develops the application to keep track of gas stations and fuel prices
User Uses the application to knwo the fuel prices of the gas stations
External IDPs Provide authetication service for users
Maps Provides the data for the map view, in particulare the available gas stations

Context Diagram and interfaces

Context Diagram

left to right direction
package "EZGaz system" {

  (mobile App)
  (web App)
}

User -- (mobile App)
User -- (web App)
(mobile App) -- :External IDPs:
(mobile App) -- Maps
(web App) -- :External IDPs:
(web App) -- Maps

Interfaces

Actor Logical Interface Physical Interface
User GUI Screen, touch input
External IDPs API Internet
Maps API Internet

Stories and personas

John needs to take a 45 to 60 minutes car dive to work everyday because his workplace is in another city. He doesn't know the prices of the gas stations close to his workplace so, when he runs short on fuel, he always needs to fill up his car close to his home. John knows pretty well the prices of the gas stations around his home because he passes near them every time he goes for a walk with his dog or goes food shopping. One day he discovers EZGaz and starts sharing it with his friends and colleagues. Every time he comes nearby a station he takes a picture of its prices and updates them on the app. This way he will be useful to other peole for the stations close to his home and , more importantly, will be able to see prices of those stations close to his workplace. This way he doesn't need to worry about fuel first thing in the morning.

John is also very happy because the app doesn't require him to add another account to his email but he can directly login using the provider he prefers, varying from Google, Facebook, Github and others.

Functional and non functional requirements

Functional Requirements

ID Description
FR1 Link to an external social account
FR2 Login
FR3 Get the stations from the map API
FR4 Render stations in a scrollable map
FR5 Find a gas station in the map based on its location, fuel type, fuel provider
FR6 Update prices of a gas station and upload their picture and record user daily updates
FR7 See the right amount of gas station's prices based on user's previous activity

Non Functional Requirements

ID Type Description Refers to
NFR1 Usability Application should be used after a short slide tutorial shown the first time a user enters the app All FR
NFR2 Performance Looking around the map for gas station needs to be smooth, without jitter FR5
NFR3 Performance Given a proper internet connection, all functions should completed in < 3 sec All FR
NFR4 Portability The application runs on Android All FR
NFR5 Portability The application (functions and data) should be portable from a phone to another in less then 5 minutes All FR
NFR6 Localisation Decimal numbers use . (dot) as decimal separator
NFR7 Localisation Prices needs to be viewed in the currency of the station country

Use case diagram and use cases

Use case diagram

left to right direction
actor User as u
actor :External IDP: as i
(FR1 - Register) as FR1
(FR2 - Login) as FR2
(FR3 - Get gas stations) as FR3
(FR4 - Render stations in a scrollable map) as FR4
(FR5 - Find a gas station based on filters) as FR5
(FR6 - Update prices of a gas station) as FR6
(FR7 - Look at prices of fuels) as FR7
actor Maps as m
u --> FR1
FR1 --> i
u --> FR2
FR2 --> i
FR3 --> m
u --> FR4
u --> FR5
u --> FR6
u --> FR7

Use Cases

Use case 1, UC1 - FR1 Register

Actors Involved User - External IDP
Precondition User is not Registered, internet connection is available
Post condition User is registered
Nominal Scenario Decides which external provider to use
Performs registration
Variants Registration with external provider goes wrong

Use case 2, UC2 - FR2 Login

Actors Involved User - External IDP
Precondition User is not logged in, internet connection is available
Post condition User Is logged in
Nominal Scenario Decides which external provider to use
Variants

Use case 3, UC3 - FR3 Get update from maps API

Actors Involved Maps
Precondition Internet connection is available
Post condition App has gas stations localization data
Nominal Scenario App is started and it pulls information from Maps API
Variants Map service is unavailable

Use case 4, UC4 - FR4 Render stations in a scrollable map

Actors Involved User
Precondition User is logged in, gas stations localization data is available
Post condition -
Nominal Scenario User looks around the map and sees all active gas station
Variants Gas stations data is unavailable

Use case 5, UC5 - FR5 Find a gas station with filters

Actors Involved User
Precondition User is logged in, gas stations localization data is available
Post condition Found only stations with certain characteristics
Nominal Scenario User enters the desired filters and then he can see he gast stations in a list on in the map
Variants Gas stations data is unavailable

Use case 6, UC6 - FR6 Update prices of a gas station

Actors Involved User - Maps
Precondition User is logged in, internet connection is available, a station is selected
Post condition Current value of station's prices and picture are the one inserted. User updates count += 1
Nominal Scenario User enters the new values and upload its picture
Variants User doesn't upload a picture

Use case 7, UC7 - FR7 Look at prices of fuels

Actors Involved Administrator
Precondition User is logged in, internet connection is available, a station is selected, user didn't reach his 3-days limit
Post condition User knows the prices of a gas station
Nominal Scenario User sees the current prices of a gas station
Variants

Relevant scenarios

Scenario 1

Scenario ID: SC1 Corresponds to UC1
Description User registers
Precondition User is not registered, internet connection is available
Postcondition User is registered
Step#
1 User selects which external IDP wants to use
2 External IDP asks for user credentials
3 User enters correct credentials
4 External IDP brings user back to the app

Scenario 2

Scenario ID: SC2 Corresponds to UC4
Description User wants to find gas statins with filters
Precondition User is logged in and internet connection is available
Postcondition User seeds only gas stations with proper characteristics
Step#
1 User enters specific filter
2 App lets user decide how to visualize results
3 User can choose betwenn map and list
4 User can scroll the list
5 User can go aroun the map a see only filtered gas stations

Glossary - Class Diagram

class EZGas
class User {
+ id
+ name
+ surname
+ nickname
+ updatesInLast3Days
+ uploadedPictures
}

class Station {
+ id
+ location
+ timeTable
+ priceTableAvg
}

class PriceTable {
+ id
+ prices
+ picture
}


class Map
class MapsAPI
class ExternalIDP

EZGas -up- MapsAPI :getData
EZGas -up-  ExternalIDP :login/register

EZGas -- "*" User
Map -- "*" Station
EZGas -- Map
Station  *-right- "*" PriceTable
User -- Station :addPriceTable

UI Prototype