Abstract
This paper presents a method for unique renaming declarations and references in Java programs using source transformation to XML markup. Each entity declaration and reference in the Java program is assigned a globally unique identifier (UID) based on its declaration scope and file. The UID serves as a key by which the entity's original declaration and all references can be found, and more importantly, by which information about the entity can be stored or retrieved from the design database. The resulting uniquely renamed source code makes it convenient and efficient to do further business logic and technical analysis that crosses the boundary between source code and the design database. UIDs are attached to entity references in the source code using XML markup, so that both the UID and the original source text of the declaration or reference are available in the renamed source program. While it is possible to generate unique names in an ad hoc manner, we show how to generate them using a combination of source transformations and design database inferences. This ensures that the notion of UID is consistent and well defined.