Parkey Project 2019: Brikelda Liçaj Elisa Pashku Sara Mboqe Xhemal Kodragjini
Parkey Project 2019: Brikelda Liçaj Elisa Pashku Sara Mboqe Xhemal Kodragjini
2019
Brikelda Liçaj
Elisa Pashku
Sara Mboqe
Xhemal Kodragjini
2
TABLE OF CONTENTS
Table of Figures ................................................................................................................................................. 3
Glossary of Terms .............................................................................................................................................. 5
1. INTRODUCTION ..................................................................................................................................... 6
3. PLANNING ............................................................................................................................................. 15
4. IMPLEMENTATION .............................................................................................................................. 21
5. TESTING ................................................................................................................................................ 36
3
Table of Figures
Figure 1. Client Interface request ............................................................................................... 10
Figure 2. Activity Diagram ....................................................................................................... 16
Figure 3. State Diagram ............................................................................................................ 17
Figure 4. Sequence Diagram...................................................................................................... 18
Figure 5. Sequence Diagram...................................................................................................... 19
Figure 6. Sequence Diagram...................................................................................................... 20
Figure 7. ER MODEL .............................................................................................................. 24
Figure 8. ER MODEL 2 ............................................................................................................ 25
Figure 9. App design ................................................................................................................ 34
Figure 10. Class Diagram .......................................................................................................... 35
Figure 11 Unit testing ............................................................................................................... 37
4
Glossary of Terms
Application (App): a software program designed to perform specific functions for a user.
Coupon: a ticket or document that can be redeemed for a financial discount or rebate when purchasing
a product.
Customer: a person or organization that buys goods or services from a store or business. It this report,
Customer account: a user account to access the application as a consumer that allows them to reserve
Database: a structured set of data stored on the ParKey network, certain parts of which are accessible
QR Code: is the trademark for a type of matrix barcode (or two-dimensional barcode. In this report,
the QR code is used for customers to confirm having received the coupon)
User interface: the visual aspect of the android application on the user’s phone that allows user
1. INTRODUCTION
1.1 Problem Statement
More and more the traffic is increasing in our city, creating chaos, air and acoustic pollution, and
citizen frustration. Furthermore, parking areas are limited. There is no structure or entity to organize
the placement of vehicles in parking spots.
1.3 Novelty
ParKey aims to create a network of connected mobility between drivers to reduce the parking problems
in major cities. Using an AI Parking Assistant, Vinny, the intermediate coordinator between
anonymous drivers, Vinny coordinates and guides drivers through voice recognition to alternative
parking options with the all-in-one access to finding parking availability in the cities. ParKey
introduces a unique GPS Navigational experience, redirecting a driver’s focus on safety, traffic
efficiency and organized correlations engaging drivers in a stress-free parking experience.
7
Business Case
User interface
State diagram
1 Brikelda Licaj
Database description & ER Model 1
Unit Testing
List of Prioritized Risks
Stakeholders
Sequence diagram – searching
Pre-coding essentials
2 Elisa Pashku
System code
Acceptance Testing
Lessons Learnt Report
Requirements analysis
Kick-off meetings
Activity diagram
3 Sara Mboqe
Sequence diagram – login
Integration Testing
Class diagram
Introduction
Sequence diagram – parking in/out
Project presentation
4 Xhemal Kodragjini
ER Model 2
Design elements of the app
Testing Design & Conclusion
Table 1 Responsibilities
8
2. REQUIREMENTS ANALYSIS
Customer:
1. This is the first page that appears when I open the app. There is the logo of ParKey and the
version of the app.
2. In the second page I can read all the legal information, permissions, conditions and accept
them.
3. Here I can see the map with all the necessary details, including the option to park in or park
out. There is also an Options tab.
4. When I press Park in / Park out, this page appears. I login with my personal ID or password.
Other people who are using the app for the first time can register by clicking Sign Up. You can
use Facebook or Google + to login also.
11
2.4 Stakeholders
Meeting Objective: Get the project off to a great start by introducing key stakeholders, reviewing
project goals, and discussing future plans
Agenda:
• Introductions of attendees
• Background of project
Short description:
The attendees were introduced to the project. Issues and restrictions of the app were discussed, tasks
were given to the members of the team.
Tasks
Xhemal Kodragjini
3. PLANNING
3.1 Planning Kick-off meeting
Meeting Objective: Discuss the elements that will be included in the planning phase of the project and
divide the tasks for each member.
Agenda:
• Attendance list
• Brainstorming of ideas
• Tasks division
Short description:
The attendees were introduced to the topic of the meeting and points to be discussed. An evaluation of
the quality of the previous assignments was made and potential improvements for the future were
discussed. Moreover, attendees had the opportunity to discuss regarding the current phase, new
assignments were given to the members, the brainstormed were structured and represented using UML
diagrams.
Tasks
First, the user opens the application after installation. He has two possibilities 1) to accept terms and
conditions for the privacy and goes to the profile of the application 2) does not accept them and closes
the application. After doing this he goes to the profile and can create an account if he doesn’t have it or
log in if he has one. After login he enters in a new step where all possibilities of doing something with
the application are in parallel and aren’t dependent from each other. Then after he reach the destination
he closes the application.
17
First, the user opens the application in order to register. After being registered (filling in all the
required information), he/she logs in with the username and password.
Now the user can see the dashboard which provides information about the free parking spots within the
area, discounts and offered coupons. Moreover, the user can park in (find a free parking spot and
occupy it). After some time, the user can park out, meaning that the spot will become available again
for another user.
18
This is the sequence diagram for the log in process. The objects are: the user, the application and the
database. The person enters their credentials (username and password). If the username and password
are correct (it is checked on the database), the user can use the application and its features.
If the credentials are not correct (mistyping, null, or not registered), the user is required to try again.
19
This sequence diagram represents the searching process where the objects are the same (user,
application, database). The user has to type their username and password which has to be verified on
the database if there is a match. If the user is registered, he/she can write the address, request a parking
space and automatically the database updates itself (meaning the space is reserved on the database).
If the user is not registered, an alert dialog pops up and suggests the user to register.
20
The last sequence diagram is for the park-out with respective objects: the user, the application and the
database. After finishing, the user requests to park out. The application sends him/her a confirmation
message and automatically updates the database (the spot is freed and added to free spaces). Moreover,
the application informs the user for the bonus he/she earned and the bonus is recorded on the database.
21
4. IMPLEMENTATION
Kick-Off Meeting
Meeting Objective: Discuss the elements that will be included in the implementation phase of the
project and divide the tasks for each member.
Agenda:
• Attendance list
• Brainstorming of ideas
• Tasks division
Short description:
The attendees were introduced to the topic of the meeting and points to be discussed. An evaluation of
the quality of the previous assignments was made and potential improvements for the future were
discussed. Moreover, attendees had the opportunity to discuss regarding the current phase, new
assignments were given to the members.
Tasks
Admin:
• Login: The system is under supervision of admin who manages the bookings made.
• Add Slots: Admin adds Parking slots with all its information.
• View Feedback: The admin can view all the feedbacks sent by the users.
• View Users: The admin can see all the users registered into the system.
• View Booking: The system will give all the booking information against start and end dates as
inputs.
User:
• User login/registration: Users have to first register themselves to login into the system.
• Parking availability check: User can click on spaces to view the availability. If the space is
already booked it will be marked red and the available ones will be seen in white color.
• Parking cancellation: User may even cancel their bookings by login into the system anytime.
• Profile: The system will show all the user details, wallet balance and valid bookings.
• Feedback: The system has a feedback form, where user can provide feedback into the system.
Software Requirements:
• Windows 7 / 10
• SQL 2017
23
Advantages:
• Users can get learn about parking areas for particular locations.
• It saves user time in search of parking space available in such a long parking area.
• The system provides a graphical view of the parking spaces.
• User can pay online on the spot and confirm their space.
• It excludes the need of human efforts for managing parking spaces.
• The system generates online bill for requested time and even sends an email.
• Cost-effective.
Disadvantages:
• It requires an internet connection.
• It requires large database.
Applications:
• The project can be implemented in commercial areas for employee parking.
• It can be utilized by companies and organizations (hospitals, schools, colleges) to automate
their parking system.
• The system can also be used in public places for public parking like in malls, station, and so on.
24
Figure 7. ER MODEL
25
Figure 8. ER MODEL 2
26
In this section, we explain the creation of registration/login form for the app.
Login
The first layout contains a background image (imageView), a textView for the name of the app, two
labels for the username and password, two editTexts for hinting the user to insert their credentials and
a login button. Moreover, there is a checkbox which allows the user to save the credentials. By
checking the box, the app will save the credentials using cookies and will not need to insert them
manually everytime he/she uses the app.
- The setOnClickListener() method,which will represent the logic happening on the background when
the user clicks the login button. When clicking the button, another method will be called, which will
search on the database if there already exists a user with the credentials inserted
If the credentials exist on the database, the user will successfully login and another layout will appear.
If the credentials do not exist, an alertDialog will appear, notifying the user to register by clicking the
register icon.
If the username and password do not match, an error will occur, notifying the user to reenter his
password.
27
Registration
This layout will contain an image in background, a textView as a welcoming message and 5 editTexts
for the information that first-time users must provide in order to register. Also, for legal purposes, the
users must accept the privacy policy and terms&conditions, which will be created using checkboxes.
At the end, there is a button for completing the registration process.
- The setOnClickListener() method,which will represent the logic happening on the background when
the user clicks the register button. When clicking the button, the entered data will be saved in the
database. Prior to registering, the user must accept the terms & conditions and privacy policy. When
the register button is clicked, the login activity will appear.
package com.sourcey.materiallogindemo;
import android.app.ProgressDialog;
import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import android.util.Log;
import android.content.Intent;
import android.view.View;
import android.widget.Button;
import android.widget.EditText;
28
import android.widget.TextView;
import android.widget.Toast;
import butterknife.ButterKnife;
import butterknife.InjectView;
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_login);
ButterKnife.inject(this);
_loginButton.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
login();
}
});
_signupLink.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
// Start the Signup activity
29
if (!validate()) {
onLoginFailed();
return;
}
_loginButton.setEnabled(false);
new android.os.Handler().postDelayed(
new Runnable() {
public void run() {
// On complete call either onLoginSuccess or onLoginFailed
onLoginSuccess();
// onLoginFailed();
progressDialog.dismiss();
30
}
}, 3000);
}
@Override
protected void onActivityResult(int requestCode, int resultCode, Intent data) {
if (requestCode == REQUEST_SIGNUP) {
if (resultCode == RESULT_OK) {
@Override
public void onBackPressed() {
// disable going back to the MainActivity
moveTaskToBack(true);
}
_loginButton.setEnabled(true);
}
31
if (email.isEmpty() || !android.util.Patterns.EMAIL_ADDRESS.matcher(email).matches()) {
_emailText.setError("enter a valid email address");
valid = false;
} else {
_emailText.setError(null);
}
return valid;
}
}
res/layout/activity_login.xml
<LinearLayout
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingTop="56dp"
android:paddingLeft="24dp"
android:paddingRight="24dp">
<ImageView android:src="@drawable/parkeyLogo"
android:layout_width="wrap_content"
android:layout_height="72dp"
android:layout_marginBottom="24dp"
android:layout_gravity="center_horizontal" />
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:inputType="textPassword"
android:hint="Password"/>
</android.support.design.widget.TextInputLayout>
<android.support.v7.widget.AppCompatButton
android:id="@+id/btn_login"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_marginTop="24dp"
android:layout_marginBottom="24dp"
android:padding="12dp"
android:text="Login"/>
<TextView android:id="@+id/link_signup"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="24dp"
android:text="No account yet? Create one"
android:gravity="center"
android:textSize="16dip"/>
</LinearLayout>
</ScrollView>
34
• The theme chosen for the design will be dark, taking into consideration the fact that drivers will
• The colors of pin points are pulsing and bright to emphasize and make a contrast so that drivers
• The current location is displayed in light blue and the position of the destination in yellow.
• There are two buttons for parking in and out, in round blue colors. Also, there is a voice
LOGO
• At the bottom of the serif of P letter there are scratches that symbolize the marks left by cars.
• In background, there are two quarter circles in blue, symbolizing the wheels of cars.
Class diagram
5. TESTING
Kick-Off Meeting
Meeting Objective: Discuss the elements that will be included in the testing phase of the project and
divide the tasks for each member.
Agenda:
• Attendance list
• Brainstorming of ideas
• Tasks division
Short description:
The attendees were introduced to the topic of the meeting and points to be discussed. An evaluation of
the quality of the previous assignments was made and potential improvements for the future were
discussed. Moreover, attendees had the opportunity to discuss regarding the current phase, new
assignments were given to the members.
Tasks
The primary goal of unit testing is to take the smallest piece of testable software in the application,
isolate it from the remainder of the code, and determine whether it behaves exactly as you expect. Each
unit is tested separately before integrating them into modules to test the interfaces between modules.
Unit testing has proven its value in that a large percentage of defects are identified during its use. Since
we are writing codes using Java we choose to use Arquillian, a Java Unit Testing Framework. As we
identify each class in the component is extensively tested using Arquillian.
Intro to Arquillian
Arquillian is a highly innovative and extendible testing platform for JVM that allows developers to
easily create automated integration, functional and acceptance tests for Java. Arquillian allows you to
run test in the run-time so you don’t have to manage the run-time from the test (or the build).
Arquillian can be used to manage the life cycle of the container (or containers),bundling test cases,
dependent classes and resources. It is also capable of deploying archive into containers and execute
tests in the containers and capture results and create reports.
Arquillian integrates with familiar testing frameworks such as JUnit 4, TestNG 5 and allows tests to be
launched using existing IDE, and because of its modular design it is capable of running Ant and Maven
test plugins.
38
In writing the tests before we wrote the class, we have been forced to do a few things. First of all, we
had to invent the class’s public API before anything else. It’s worth noting that in Unit Testing and
TDD, it is virtually pointless to test private methods (what’s called “Testing State”) since we’re rarely
interested in how the code does something as opposed to what the expected end result should be (focus
on results, not intermediate state). In a lot of code the result will remain the same, but the working code
will evolve over time due to refactoring, new Arquillian functionality, or system dependent
requirements – so testing all this stuff only forces us to constantly rewrite our tests. Once we get down
to actual coding, we have all this design work already done and a set of tests which will continually
verify the new code we write.
39
Integration testing is a logical extension of unit testing. In its simplest form, two units that have already
been tested are combined into a component and the interface between them is tested. A component, in
this sense, refers to an integrated aggregate of more than one unit. In a realistic scenario, many units
are combined into components, which are in turn aggregated into even larger parts of the program. The
idea is to test combinations of pieces and eventually expand the process to test your modules with
those of other groups. Eventually all the modules making up a process are tested together. Beyond that,
if the program is composed of more than one process, they should be tested in pairs rather than all at
once. Integration testing identifies problems that occur when units are combined. By using a test plan
that requires you to test each unit and ensure the viability of each before combining units, you know
that any errors discovered when combining units are likely related to the interface between units. This
method reduces the number of possibilities to a far simpler level of analysis.
You can do integration testing in a variety of ways and we have chosen the Umbrella approach:
The umbrella approach requires testing along functional data and control-flow paths. First, the
inputs for functions are integrated in the bottom-up pattern discussed above. The outputs for each
function are then integrated in the top-down manner. The primary advantage of this approach is the
degree of support for early release of limited functionality. It also helps minimize the need for stubs
and drivers. We have chosen this model as the functional issues can be detected early and also as our
project requires maintenance, the regression testing scenario would not be a overhead for following
this pattern in testing.
CODE COVERAGE:
Code coverage is a measure used in software testing. It describes the degree to which the source code
of a program has been tested. We have used XDEBUG Extension and it gives us the function coverage
statistics as well as statement coverage statistics .We have observed that the function coverage was
100%, however statement coverage was 60% as many branches would never be executed with any
piece of testing.
40
Login section
Integration Testing
Steps:
• Register by entering all the required information
• Click the register button
Fails if:
Parking in
Integration Testing
Steps:
• Search for the parking area you want to park in.
• Choose the parking block and spot.
• Click “Park in”
Fails if:
• In the moment that the user is choosing the block and spot, another user parks in.
• The place is not free, but this is not updated in the system.
42
Integration Testing
Steps:
• Go to the “Bonus” menu in the app
• Click on the “Get a coupon” button
• Wait for the page to load the discount you have received.
Expected: User receives the coupon and discount from one of the partner companies.
Fails if:
Acceptance tests are created from user stories. During iteration the user stories selected during the
iteration planning meeting will be translated into acceptance tests. A story can have one or many
acceptance tests, whatever it takes to ensure the functionality works. Acceptance tests are black box
system tests. Each acceptance test represents some expected result from the system. Customers are
responsible for verifying the correctness of the acceptance tests and reviewing test scores to decide
which failed tests are of highest priority. Acceptance tests are also used as regression tests prior to a
production release.
ATC3.01- Access the user profile who is not currently logged in. (Fail)
ATC3.03- The system logs out after being idle for 10 minutes. (Pass)
ATC3.04- The user enters the system after 3 consecutive failed attempts to login. (Fail)
ATC3.05 The user retrieves his password by answering the secret question (Pass)
ATC3.07- The user tries to login with a wrong user id or password. (Fail)
44
ATC4.01-The system displays the list of all the user ID and password when the administrator
logs in (Pass)
ATC4.02-The system does not show any user ID and password when the administrator logs in
(Fail)
45
Below are the design of the test cases as per required by out project. These are the basic test
cases. We need to check thoroughly that all the test cases are working properly, the screens are
displayed in a proper format and there is no discrepancy in displayed graphs. We also need to
check the code thoroughly for the correctness of algorithm and control flows.
1. Test ID : TC1_Login
2. Test ID : TC2_Register
We did meet the scope and time goal, but the cost exceeded a bit. We actually exceeded scope goals by
having more people install and use our app compared to our user’s goal.
2. What was the success criteria listed in the project scope statement?
Our group has stated that the project will be a success if the parking app will be developed on time
providing all the features, and 50 users will install and use it within the first week of launching.
The parking app was developed on time, but one feature was not developed as we had planned. We had
to rethink and evaluate again the gender of the virtual assistant, and for clarity purposes, we chose to
4. In terms of managing the project, what were the main lessons your team learned?
Having good communicational and organizational was a key factor to the success of our app. Writing
reports and keeping notes were two other important factors which made Parkey a full-option parking
app. Using ready dynamic libraries, helped us design the layout of the app easily. It was extremely
helpful to take time to develop and follow a team contract for the project team and to focus on
47
developing good partnerships with suppliers. Everyone was very supportive of each other.
Creativity and innovation are infectious: Many creative and innovative ideas were used on this project.
We were a little bit skeptical about the team spirit but actually everything went great and our
discussions were really productive. Moreover, we are really proud of the design of the app.
We had some difficulty integrating Google Maps inside the app. Google Maps needed constant
updates.
7. What will you do differently on the next project based on your experience working on this
project?
For future projects, it would be better not to underestimate the number of people who will take interest
and use our products. We should have more faith in our output as long as we put all our effort on the
project.
48
CONCLUSION
As a first draft, this prototype was focusing on usability for users with limited technical experience.
The prototype aimed at simplifying the process of finding parking spots. The draft features a “login”
option which enables the user to use the main features of the app. The design for this application is
aimed at providing the user with detailed information, which would aid them to make a choice of
where to park based on their needs and level of convenience; however, this may add too much
cognitive load.
The cognitive process of finding a car parking space and parking needs to be reduced in order to
enhance the efficiency of use for the user. For a novice user the process might be technically
challenging, equally an experienced mobile application user might find the interaction.
The next step is to provide a “voice” experience, by making the user communicate with a Virtual
Assistant, called Vinny, which will guide the user to the destination.
50
REFERENCES
Study of Parking Patterns for Different Parking Facilities. (october 2014 - march 2015). International Journal of
https://www.researchgate.net/publication/272680565_Study_of_Parking_Patterns_for_Different_Parking_Facilities.