Generating program source code based on design model by using CASE tool is one of the important areas in forward engineering. The generation of code from design model is valuable in making developers maintain consistency between a model and its implementation and abating the routine work of writing skeleton source codes. But, implementing code generation in CASE tool is not simple due to various metadata format, language, and policies of adopting modeler's option. And because of the continuous introduction of development environment like EJB and COM, the extensibility of CASE tool becomes principal comparison point. We believe that it be a feasible solution to generating source code in various language based on generation rule.
In this paper, we propose XML based code generation rule and code generator. The proposed rule provides higher level constructs to the developer for describing the way of code generation. And by making the code generator independent of repository format, the increase of the applicability of the code generator is shown.