{"title":"Generating Code Using Reflection in the Context of Computer-Assisted Legacy System Analyses and Reengineering","authors":"Peter Krall","doi":"10.1145/2688447.2688449","DOIUrl":null,"url":null,"abstract":"The paper presents a two-step approach for DSM-based generating of substantial parts of tools for legacy-system analysis. In the first step a parser is generated from a formal grammar, representing the syntax of the legacy system's code. This parser is able to recognize the constructs of the legacy code but unaware of any analytic functionality. In the second step the code for the analytic functionality and glue code for integrating the parser-generated code into a framework is generated from a domain-specific model capturing properties of and relations between code constructs to be analyzed. Integration with parser functionality generated in first step and framework is achieved by loading classes and re-trieving information using reflection and annotations in the second step.","PeriodicalId":252689,"journal":{"name":"Proceedings of the 14th Workshop on Domain-Specific Modeling","volume":"16 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"2014-10-21","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"0","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"Proceedings of the 14th Workshop on Domain-Specific Modeling","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1145/2688447.2688449","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 0
Abstract
The paper presents a two-step approach for DSM-based generating of substantial parts of tools for legacy-system analysis. In the first step a parser is generated from a formal grammar, representing the syntax of the legacy system's code. This parser is able to recognize the constructs of the legacy code but unaware of any analytic functionality. In the second step the code for the analytic functionality and glue code for integrating the parser-generated code into a framework is generated from a domain-specific model capturing properties of and relations between code constructs to be analyzed. Integration with parser functionality generated in first step and framework is achieved by loading classes and re-trieving information using reflection and annotations in the second step.