This Article 
   
 Share 
   
 Bibliographic References 
   
 Add to: 
 
Digg
Furl
Spurl
Blink
Simpy
Google
Del.icio.us
Y!MyWeb
 
 Search 
   
Lightweight Extraction of Object Models from Bytecode
February 2001 (vol. 27 no. 2)
pp. 156-169

Abstract—A program's object model captures the essence of its design. For some programs, no object model was developed during design; for others, an object model exists but may be out-of-sync with the code. This paper describes a tool that automatically extracts an object model from the classfiles of a Java program. Unlike existing tools, it handles container classes by inferring the types of elements stored in a container and eliding the container itself. This feature is crucial for obtaining models that show the structure of the abstract state and bear some relation to conceptual models. Although the tool performs only a simple, heuristic analysis that is almost entirely local, the resulting object model is surprisingly accurate. The paper explains what object models are and why they are useful; describes the analysis, its assumptions, and limitations; evaluates the tool for accuracy, and illustrates its use on a suite of sample programs.

[1] W. Bischoffberger, “Sniff: A Pragmatic Approach to a C++ Programming Environment,” Proc. USENIX C++ Conf., pp. 67-81, 1992.
[2] D. Coleman, P. Arnold, S. Bodoff, C. Dollin, and H. Gilchrist, Object-Oriented Development: The Fusion Method. Prentice Hall, 1993.
[3] S. Cook and J. Daniels, Designing Object Systems: Object-Oriented Modelling with Syntropy, Prentice Hall, New York, 1994.
[4] S.C. Choi and W. Scacchi, "Extracting and Restructuring the Design of Large Systems," IEEE Software, pp. 66-71, Jan. 1990.
[5] D. D'Souza and A.C. Wills, Objects, Components, and Frameworks with UML: The Catalysis Approach, Addison Wesley Longman, Reading, Mass., 1998.
[6] E. Gamma et al., Design Patterns: Elements of Object-Oriented Software, Addison-Wesley, Reading, Mass., 1994.
[7] D. Jackson, “Aspect: Detecting Bugs with Abstract Dependences,” Trans. Software Eng. and Methodology, vol. 4, no. 2, pp. 109–145, Apr. 1995.
[8] D. Jackson, “Alloy: A Lightweight Object Modelling Notation,” Technical Report MIT-LCS-797, MIT Laboratory for Computer Science, Cambridge, Mass., Feb. 2000, Available at:http://sdg.lcs.mit.edu/~dnjpublications.
[9] D. Jackson and J. Chapin, “Redesigning Air-Traffic Control: A Case Study in Software Design,” Software, pp. 63-70, May/June 2000.
[10] D. Jackson, I. Schechter, and I. Shlyakhter, “Alcoa: The Alloy Constraint Analyzer,” Int'l Conf. Software Eng., pp. 730-733, June 2000.
[11] P. Linos and V. Courtois, “A Tool for Understanding Object-Oriented Program Dependences,” Proc. Third Workshop Program Comprehension, pp. 20-27, Nov. 1994.
[12] G.C. Murphy and D. Notkin, “Lightweight Lexical Source Model Extraction,” ACM Trans. Programming Languages and Systems, vol. 5, no. 3, pp. 262–292, July 1996.
[13] G.C. Murphy, D. Notkin, and K. Sullivan, “Software Reflexion Models: Bridging the Gap Between Source and High-Level Models,” Proc. Third ACM SIGSOFT Symp. Foundations of Software Eng., pp. 18-28, Oct. 1995.
[14] R. O'Callahan, “Generalized Aliasing as a Basis for Program Analysis Tools,” PhD thesis, School of Computer Science, Carnegie Mellon Univ., Pittsburgh Penn., Dec. 2000.
[15] C.L. Chang, R.A. Stachowitz, and J.B. Combs, “Validation of Nonmonotonic Knowledge-Based Systems,” Proc. IEEE Int'l Conf. Tools for Artificial Intelligence, Nov. 1990.
[16] J. Rumbaugh, I. Jacobson, and G. Booch, The Unified Modeling Language Reference Manual. Addison-Wesley, 1999.
[17] J.M. Spivey, The Z Notation, second ed., Prentice Hall, 1992.
[18] J. Seemann and J.W. von Gudenberg, “Pattern-Based Design Recovery of Java Software,” Proc. Foundations of Software Eng., pp. 10-16, Nov. 1998.

Index Terms:
Object model, class diagram, reverse engineering, program understanding, design conformance, lightweight analysis, type inference.
Citation:
Daniel Jackson, Allison Waingold, "Lightweight Extraction of Object Models from Bytecode," IEEE Transactions on Software Engineering, vol. 27, no. 2, pp. 156-169, Feb. 2001, doi:10.1109/32.908960
Usage of this product signifies your acceptance of the Terms of Use.