lightweight detection of android-specific code smells: the adoctor project

14
Lightweight Detection of Android-specific Code Smells: the aDoctor Project Andrea De Lucia Annibale Panichella Dario Di Nucci Fabio Palomba Andy Zaidman

Upload: dario-di-nucci

Post on 03-Mar-2017

106 views

Category:

Engineering


1 download

TRANSCRIPT

Page 1: Lightweight Detection of Android-specific Code Smells: the aDoctor Project

Lightweight Detection of Android-specific Code Smells:

the aDoctor Project

Andrea De LuciaAnnibale Panichella

Dario Di NucciFabio Palomba

Andy Zaidman

Page 2: Lightweight Detection of Android-specific Code Smells: the aDoctor Project

Bad Smells have been defined as symptoms of poor design or implementation choices.

Page 3: Lightweight Detection of Android-specific Code Smells: the aDoctor Project

Bad Smells hinder code comprehensibility

[Abbes et al. CSMR 2011]

Page 4: Lightweight Detection of Android-specific Code Smells: the aDoctor Project

[Khomh et al. EMSE 2012]

Bad Smells increasechange and fault proneness

Page 5: Lightweight Detection of Android-specific Code Smells: the aDoctor Project

Number of smartphone users worldwide from 2014 to 2020(in billions)

The statistics portal association.

Page 6: Lightweight Detection of Android-specific Code Smells: the aDoctor Project

Android-specific Code Smells

A set of bad programming practices ofAndroid developers.

Involve non-functional attributes of mobile apps.

Reimann et al. A tool-supported quality smell catalogue for android developers.2014. Modellierung 2014.

Security

Source Code Quality Performance

Data Integrity

Page 7: Lightweight Detection of Android-specific Code Smells: the aDoctor Project

An example: Data Transmission Without Compression

File sending without compression.

Page 8: Lightweight Detection of Android-specific Code Smells: the aDoctor Project

aDoctor

AnDrOid Code smell detecTOR

https://github.com/fpalomba/aDoctor

Page 9: Lightweight Detection of Android-specific Code Smells: the aDoctor Project

aDoctorAnDrOid Code smell detecTOR

15 Android Specific Code Smells

Executable via Terminal or GUI.

Data Export in CSV.

Released under MIT License.

Page 10: Lightweight Detection of Android-specific Code Smells: the aDoctor Project
Page 11: Lightweight Detection of Android-specific Code Smells: the aDoctor Project

Evaluation

What are the precision and recall scoresof aDoctor in detecting Android-specific code

smells?

18 apps

RQ

2 Students Manually Validated 1,927 Instances

98% of F-Measure98% of Precision

98% of Recall

100% of F-Measureon 13 smells

Page 12: Lightweight Detection of Android-specific Code Smells: the aDoctor Project

Future Works

Integrate aDoctor inAndroid Studio

Page 13: Lightweight Detection of Android-specific Code Smells: the aDoctor Project

Future Works

Extract and Automate Refactorings

Integrate aDoctor inAndroid Studio

Page 14: Lightweight Detection of Android-specific Code Smells: the aDoctor Project

Dario Di Nucci

University of Salerno

[email protected]

http://www.sesa.unisa.it/people/ddinucci/

Thanks for your attention!

https://github.com/fpalomba/aDoctor