Identification of Variability Implementations in TypeScript: the 2Cities Visualization

When variability is directly implemented in a single codebase with languages supporting many different mechanisms, its identification and comprehension are impeded by the absence of documentation, their scattered locations, and obviously, their diversity. This is typically the case with TypeScript in which variability can be implemented with Object-Oriented (OO) mechanisms, and design patterns, but also with dynamic loading of files. This latter mechanism allows for organizing internal variants of part of code in directories and files, usually containing code clones of different forms. In this paper, we demonstrate 2Cities, a dedicated visualization based on the city metaphor to highlight variability implementations in a single TypeScript codebase. We introduce the detection toolchain that gathers all the necessary information and variability metrics. Then we detail the visualization mechanisms that use two dedicated cities whose relations also highlight the architecture of the implementation. The first one, ObjectCity, adapts the VariCity visualization with classes as buildings shaped by their variability and usage relationships as streets. The second one, CloneCity, visualizes the directory hierarchy as streets and files as circular districts with different colors to point out duplication and cylindrical shades to highlight clones obtained from a code clone detection phase.

Authors

Institutions

Publication Details

Published
2024-08-12
DOI
https://doi.org/10.1145/3646548.3676598
Citations
2
Primary Topic
Software Engineering Research
Type
article
Field-Weighted Citation Impact
1.56
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
article

Identification of Variability Implementations in TypeScript: the 2Cities Visualization

Anne-Marie Pinna-Déry, Philippe Collet, Yann Brault
2 citations
Software Engineering Research
1.56
article

Identification of Variability Implementations in TypeScript: the 2Cities Visualization

Anne-Marie Pinna-Déry, Philippe Collet, Yann Brault
article en
2 citations

Abstract

When variability is directly implemented in a single codebase with languages supporting many different mechanisms, its identification and comprehension are impeded by the absence of documentation, their scattered locations, and obviously, their diversity. This is typically the case with TypeScript in which variability can be implemented with Object-Oriented (OO) mechanisms, and design patterns, but also with dynamic loading of files. This latter mechanism allows for organizing internal variants of part of code in directories and files, usually containing code clones of different forms. In this paper, we demonstrate 2Cities, a dedicated visualization based on the city metaphor to highlight variability implementations in a single TypeScript codebase. We introduce the detection toolchain that gathers all the necessary information and variability metrics. Then we detail the visualization mechanisms that use two dedicated cities whose relations also highlight the architecture of the implementation. The first one, ObjectCity, adapts the VariCity visualization with classes as buildings shaped by their variability and usage relationships as streets. The second one, CloneCity, visualizes the directory hierarchy as streets and files as circular districts with different colors to point out duplication and cylindrical shades to highlight clones obtained from a code clone detection phase.

Centre National de la Recherche Scientifique (FR), Université Côte d'Azur (FR), Laboratoire d'Informatique, Signaux et Systèmes de Sophia Antipolis (FR), Observatoire de la Côte d’Azur (FR), Infection et inflammation (FR)
Openalex Percentile: Top 13%
Software Engineering Research
1.56
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.

Identification of Variability Implementations in TypeScript: the 2Cities Visualization — Anne-Marie Pinna-Déry, Philippe Collet, et al. · (2024) | TGRS Research Map | TGRS