M. Z. I. Nazir, M. Alqaradaghi, and T. Kozsik 

Automated checker for detecting method-hiding in Java  programs 

Method overriding is a valuable mechanism that happens when an instance method is defined in a subclass and has the same signature and return type as an instance method in the superclass. However, in Java, if those methods are static, then instead method hiding happens, which is a programming weakness and may produce unexpected results. Static analysis is an approach in software testing that examines code to identify various programming weaknesses throughout the software de velopment process without running it. This paper addresses the detection of method-hiding problem in Java programs. We implemented a new automated checker under the SpotBugs static analysis tool that can detect the mentioned problem. According to our results, the checker precisely detected zhe related issues in both custom test cases and realword programs.

Reference:

DOI: 10.36244/ICJ.2024.2.3

Download 

Please cite this paper the following way:

M. Z. I. Nazir, M. Alqaradaghi, and T. Kozsik , "Automated checker for detecting method-hiding in Java  programs ", Infocommunications Journal, Vol. XVI, No 2, June 2024, pp. 19-24., https://doi.org/10.36244/ICJ.2024.2.3

 

Technical Co-Sponsors


  

  

Supporter



 

National Cooperation Fund, Hungary