Browse Prior Art Database

Overlaying Editor for Object Oriented Code

IP.com Disclosure Number: IPCOM000011983D
Original Publication Date: 2003-Mar-28
Included in the Prior Art Database: 2003-Mar-28
Document File: 2 page(s) / 84K

Publishing Venue

IBM

Abstract

With Object Oriented code that involves inheritance, it is sometimes very hard to look at a class and know exactly what piece of code is going to get executed. Is it in the current class, or one of the super classes? Things get more complex when code is overridden. Extra complexity is added when, in languages such as Java, field elements can be hidden rather being overridden. An idea for a new format of editor is suggested below.

This text was extracted from a PDF file.
At least one non-text object (such as an image or picture) has been suppressed.
This is the abbreviated version, containing approximately 81% of the total text.

Page 1 of 2

Overlaying Editor for Object Oriented Code

With Object Oriented code that involves inheritance, it is sometimes very hard to look at a class and know exactly what piece of code is going to get executed. Is it in the current class, or one of the super classes? Things get more complex when code is overridden. Extra complexity is added when, in languages such as Java*, field elements can be hidden rather being overridden. An idea for a new format of editor is suggested below.

     The essential idea is to present a single file to the user. Based upon the position in the hierarchy, the code presented would be merged from various points in the hierarchy. The best description of this idea is with reference to the following 2 object example:

     Circle will inherit the location functions from Shape. The Overlaying Editor would show the following when looking at Circle. The important thing to note is that the code that is inherited from Shape is actually included, and highlighted in some way (eg in a different colour). In the following, the inherited code is shown in italics:

import java.util.*;

public class Circle extends Shape {

private int location_X;

private int location_Y;

private int radius;

public int getLocation_X() {

return location_X;

}

public void setLocation_X(int _location_X) {

location_X = _location_X;

}

[This page contains 1 picture or other non-text object]

Page 2 of 2

public int getRadius() {

return radius;

}

public void setRadius(int _radius) {

radius = _radius;...