Janina's Design Study

From CSSEMediaWiki
(Difference between revisions)
Jump to: navigation, search
(Requirements)
Line 10: Line 10:
 
*Visit the JST model of a Java program to extract information about fields, methods and accesses to fields and methods.
 
*Visit the JST model of a Java program to extract information about fields, methods and accesses to fields and methods.
 
*Analyse the accesses to methods and fields and present information to the user of the program. Part of this is deciding whether the program uses class or object encapsulation or both.
 
*Analyse the accesses to methods and fields and present information to the user of the program. Part of this is deciding whether the program uses class or object encapsulation or both.
 +
*If the user wants, the program should go through the Java code and tighten the access modifiers as far as possible before writing the modified Java code back out to file.
  
 
==JST==
 
==JST==

Revision as of 09:26, 25 July 2009

As part of my honours project, I am working on a program to analyse the encapsulation in software. This program uses Wal's JST (at least will use JST once it works :)) to extract information from Java code.

I originally didn't put much effort into my design so it has about 4 classes and is pretty ugly in its current state. Part of the reason why I decided to use this for my design study is that I know that the code isn't too pretty at the moment and I want to improve it. I also chose it because I think the code could become unmanageable if I worked with it a lot more. At least because the current design is so ugly there should be lots I can improve on.

I will first describe the requirements for my program to get my head around exactly what I need my program to do. I will then give a short introduction to JST for those readers who are not familiar with what it is and how it works. Then, I will present and critique my current design and show all the design heuristics I have broken before making an attempt to improve the design.

Contents

Requirements

The program needs to be able to:

  • Visit the JST model of a Java program to extract information about fields, methods and accesses to fields and methods.
  • Analyse the accesses to methods and fields and present information to the user of the program. Part of this is deciding whether the program uses class or object encapsulation or both.
  • If the user wants, the program should go through the Java code and tighten the access modifiers as far as possible before writing the modified Java code back out to file.

JST

Initial Design

Design Critique

Personal tools