java code
Recently Published Documents


TOTAL DOCUMENTS

200
(FIVE YEARS 38)

H-INDEX

15
(FIVE YEARS 2)

Electronics ◽  
2022 ◽  
Vol 11 (2) ◽  
pp. 201
Author(s):  
Paolino Di Felice ◽  
Gaetanino Paolone ◽  
Romolo Paesani ◽  
Martina Marinelli

Model-Driven Engineering is largely recognized as the most powerful method for the design of complex software. This study deals with the automated archival of metadata about the content of UML class diagrams (a particularly relevant category of models) into a pre-existing repository. To define the structure of the repository, we started from the definition of a UML metamodel. From the latter, we derived the schema of the metadata repository. Then, a parser was developed that is responsible for extracting the useful information from the XMI file about class diagrams and enters it as metadata into the repository. The parser has been implemented as a Java web interface, while the metadata repository has been implemented as a PostgreSQL database based on the JSONB data type. The metadata repository is thought to support modelers in the initial phase of the process of the development of new models when looking for artifacts to start from. The schema of the metadata repository and the Java code of the parser are available from the authors.


2021 ◽  
Vol 27 (2) ◽  
Author(s):  
Stefan Hanenberg ◽  
Nils Mehlhorn

AbstractIn Java, lambda expressions (LEs) were introduced at a time where the similar language construct anonymous inner class (AIC) already existed for years. But while LEs became quite popular in mainstream programming languages in general, their usability is hardly studied. From the Java perspective the need to study the relationship between LEs and AICs was and is quite obvious, because both language constructs co-exist. However, it is quite usual that new language constructs are introduced although they are not or hardly studied using scientific methods – and an often heard argument from programming language designers is that the effort or the costs for the application of the scientific method on language constructs is too high. The present paper contributes in two different ways. First, with respect to LEs in comparison to AICs, this paper presents two N-of-1 studies (i.e. randomized control trials executed on a single subject) where LEs and AICs are used as listeners in Java code. Both experiments had two similar and rather simple tasks (“count the number of parameters”, respectively “count the number of used parameters”) with the dependent variable being reaction time. The first experiment used the number of parameters, the second the number of used parameters as the controlled, independent variable (in addition to the technique LE and AIC). Other variables (LOC, etc.) were randomly generated within given boundaries. The main result of both experiments is that LEs without type annotations require less reading time (p hs .2, reduction of reaction time of at most 35%). The results are based on 9,600 observations (one N-of-1 trial with eight replications). This gives evidence that the readability of LEs without type annotations improves the readability of code. However, the effect seems to be so small, that we do not expect this to have a larger impact on daily programming. Second, we see the contribution of this paper in the application of N-of-1 trials. Such experiments require relatively low effort in the data selection but still permit to analyze results in a non-subjective way using commonly accepted analysis techniques. Additionally, they permit to increase the number of selected data points in comparison to traditional multi–subject experiments. We think that researchers should take such experiments into account before planning and executing larger experiments.


2021 ◽  
Author(s):  
Zak Risha ◽  
Jordan Barria-Pineda ◽  
Kamil Akhuseyinoglu ◽  
Peter Brusilovsky
Keyword(s):  

2021 ◽  
Vol 5 (OOPSLA) ◽  
pp. 1-31
Author(s):  
Alexandru Dura ◽  
Christoph Reichenbach ◽  
Emma Söderberg

Static checker frameworks support software developers by automatically discovering bugs that fit general-purpose bug patterns. These frameworks ship with hundreds of detectors for such patterns and allow developers to add custom detectors for their own projects. However, existing frameworks generally encode detectors in imperative specifications, with extensive details of not only what to detect but also how . These details complicate detector maintenance and evolution, and also interfere with the framework’s ability to change how detection is done, for instance, to make the detectors incremental. In this paper, we present JavaDL, a Datalog-based declarative specification language for bug pattern detection in Java code. JavaDL seamlessly supports both exhaustive and incremental evaluation from the same detector specification. This specification allows developers to describe local detector components via syntactic pattern matching , and nonlocal (e.g., interprocedural) reasoning via Datalog-style logical rules . We compare our approach against the well-established SpotBugs and Error Prone tools by re-implementing several of their detectors in JavaDL. We find that our implementations are substantially smaller and similarly effective at detecting bugs on the Defects4J benchmark suite, and run with competitive runtime performance. In our experiments, neither incremental nor exhaustive analysis can consistently outperform the other, which highlights the value of our ability to transparently switch execution modes. We argue that our approach showcases the potential of clear-box static checker frameworks that constrain the bug detector specification language to enable the framework to adapt and enhance the detectors.


Author(s):  
Guanglei Wang ◽  
Junhua Chen ◽  
Jianhua Gao ◽  
Zijie Huang

Code smell is a software quality problem caused by software design flaws. Refactoring code smells can improve software maintainability. While prior works mostly focused on Java code smells, only a few prior researches detect and refactor code smells of Python. Therefore, we intend to outline a route (i.e. sequential refactoring operation) for refactoring Python code smells, including LC, LM, LMC, LPL, LSC, LBCL, LLF, MNC, CCC and LTCE. The route could instruct developers to save effort by refactoring the smell strongly correlated with other smells in advance. As a result, more smells could be resolved by a single refactoring. First, we reveal the co-occurrence and the inter-causation between smells. Then, we evaluate the smells’ correlation. Results highlight seven groups of smells with high co-occurrence. Meanwhile, 10 groups of smells correlate with each other in a significant level of Spearman’s correlation coefficient at 0.01. Finally, we generate the refactoring route based on the association rules, we exploit an empirical verification with 10 developers involved. The results of Kendall’s Tau show that the proposed refactoring route has a high inter-agreement with the developer’s perception. In conclusion, we propose four refactoring routes to provide guidance for practitioners, i.e. {LPL [Formula: see text] LLF}, {LPL [Formula: see text] LBCL}, {LPL [Formula: see text] LMC} and {LPL [Formula: see text] LM [Formula: see text] LC [Formula: see text] CCC [Formula: see text] MNC}.


Author(s):  
A.-M. Boutsi ◽  
S. Verykokou ◽  
S. Soile ◽  
C. Ioannidis

Abstract. Augmented Reality (AR) is more than an added value for Cultural Heritage (CH); it is vital for its sustainability, promotion and dissemination, increasing accessibility in CH even during difficult periods of time, like the Covid-19 pandemic. In order to be meaningful and engaging, an AR application should have the following characteristics: easiness of use, high-quality representations and compatibility. This paper presents a marker-less mobile AR application for the display and inspection of high-resolution 3D cultural assets, overlayed on a particular location in the real-world scene. Instead of predefined markers, an image captured by the user is exploited as a pattern for real-time feature matching, pose estimation and scene augmentation. Our approach is based on pure computer vision and photogrammetric techniques, implemented using native C++ and Java code for Android mobile platforms. It is built with the use of the OpenCV library and the OpenGL ES graphics API without any dependencies of AR Software Development Kits (SDKs). Therefore, it supports cross-vendor portability regarding mobile model devices and hardware specifications. The evaluation of the developed application examines the performance of various matching techniques and the overall responsiveness of processing and 3D rendering on mid-range and low-end smartphones. The results showcase the reliability and responsiveness of the pattern recognition as well as the potential of the 3D graphics engine to render and overlay complex 3D models balancing between visual quality and time. The proposed methodology is applied to the Ciborium of the church of St. Charalabos, located at St. Stephen’s Monastery in Meteora, Greece.


Author(s):  
Nassima Yamouni-Khelifi ◽  
Kaddour Sadouni ◽  
Michał Śmiałek ◽  
Mahmoud Zennaki

Requirements definition is the first step in the life cycle of a software system. Requirements are formulated as paragraphs of text and appear ambiguous, so they cannot be translated directly into code. For this reason, they are treated as secondary artifacts for software developers. This paper presents a model-driven based approach where requirements are treated as first-class citizens, and can contribute to the final code. In this approach, requirements are formulated as use case models with their textual scenarios, using a precise requirements language called RSL, allowing an automatic transition to executable Java code. The structure of the generated code follows the Model-View-Presenter (MVP) architectural pattern. The work focuses on the Model layer code, which is responsible for the persistence and storage of data in a database system.


Sign in / Sign up

Export Citation Format

Share Document