Applying reflection in object-oriented software design

Abstract

thesis work performs a series of experiments on applying reflection technique to improve software design. First, a REFLECTIVE V ISITOR pattern was captured to improve the traditional VISITOR pattern. Reflection enables a visitor to perform a run-time dispatch action on itself. The cyclic dependencies between the visitor structure and the element structure are broken, thus both of them can be reused independently. Secondly, a parser framework was developed by applying several patterns. Especially, the REFLECTION pattern is used in the design of dynamically handling a parsing process by separating the system into two levels. The base-level defines the grammar rules. The meta-level handles the complex relationships of these rules. Reflection technique is used to discover grammar rules at run-time and determines the parsing order. Third, a dynamic object model was defined for a virtual machine that can support reflection. We demonstrated Forman's theory by developing a simplified object model based on a single inheritance system with the support of only one metaclass. Finally, an extensible and reusable compiler system (front-end) for the Decaf programming language was designed and implemented

    Similar works