Roles of Variables Home Page
Sajaniemi J., Byckling P., Gerdt P. (2006)
Animation Metaphors for Object-Oriented Concepts
Accepted to the Fourth Program Visualization Workshop (PVW 2006), Florence, Italy, June 2006.
Introduction: Program visualization and animation has traditionally been done at the level of the programming language and its implementation in a computer. For example, variables have been visualized as boxes (representing memory locations), and nested function calls as a stack of frames containing parameters and local variables (representing the call stack implementation in many computer architectures). In object-oriented (OO) context, animation has also been based on UML diagrams that reveal connections between objects and classes and thus represent another level, i.e., relationships between components of an individual program. We know of only one program animation system, PlanAni (Sajaniemi and Kuittinen, 2004), that builds its visualization on general programming knowledge (roles of variables) and uses metaphors to make this knowledge easier to assimilate by learners.
Novices have problems in learning the very basic OO concepts which results in misconceptions leading to either erroneous or suboptimal programming skill (see, e.g., Eckerdal and Thuné(2005); Fleury (2000); Holland et al. (1997)). Program visualization is supposed to enhance learning and prevent misconceptions but the visualizations should be at the same level as the concepts to be learned. Thus visualizations that build upon programming language implementation may easily fail in helping novices to learn programming concepts.
Metaphor involves the presentation of a new idea in terms of a more familiar one (Carroll and Mack, 1999). In contrast to analogy, metaphor is not an exact counterpart but differs from the idea usually both in form and in content. The similarities and differences between the two ideas stimulate thought and can facilitate active learning. This paper applies a metaphor approach to object-oriented programming. Our ultimate goal is to provide novices with metaphors that will help them in learning basic OO constructs. For this purpose, we present new metaphors for such concepts as object, object instantiation, method invocation, parameter passing, and object reference. The metaphors are designed to grasp the basic ideas of object-oriented programming; they do not rely on implementation issues or diagramming techniques designed for expert use.
Back to the literature page
Last updated: May 23, 2006