Abstract

ContextAchieving hundred percent automation in code generation process from Unified Modeling Language (UML) models will make a drastic advancement in software industry. UML does not use a fully formalized semantics. So it leads to ambiguity during automatic implementation of UML models. These ambiguities can be avoided to a large extent using Object Constraint Language (OCL). OCL is formal and user friendly which is also familiar to industry people. ObjectiveThis paper examines how to improve the code generation from UML models, with the help of Object Constraint Language. It also explores the possibilities to incorporate OCL in UML activity models and generate code from the OCL enhanced activity diagrams. MethodMeta models for the association of OCL expressions with the UML activity diagram is proposed in the paper. OCL expressions are added as part of the UML activity models to improve the code generation and to specify assertions and behavior. Moreover a tool, called ActivityOCLKode, is implemented which follows the algorithm for code generation. The algorithm is depicted in the text. ResultsThe tool which is implemented based on the proposed method gives a promising result. More than 80% of source code is generated using the tool. In addition, the average execution time for our approach is only 11.46 ms. ConclusionThe meta model proposed in the paper gives the strong theoretical back ground to attach OCL statements with each element in the UML activity diagrams. The proposed method of code generation will improve the productivity of the software industries, since it reduces the software development effort and time. Since UML and OCL are commonly used in software industry, our method is easily adaptable by software programmers in industry.

Full Text
Published version (Free)

Talk to us

Join us for a 30 min session where you can share your feedback and ask us any queries you have

Schedule a call