How to automate the generation of HTML output in Enterprise Architect

前端 未结 2 1663
悲&欢浪女
悲&欢浪女 2021-02-03 12:14

Enterprise Architect has a way to generate the documentation in HTML/RTF/etc. that you could publish, but you have to use its GUI to do that manually. When you have your *.eap f

2条回答
  •  予麋鹿
    予麋鹿 (楼主)
    2021-02-03 12:57

    Thanks chimp, It was easier than I thought. In Java:

    class EADump
    {
        public static void main(String[] args)
        {
         org.sparx.Repository r = new org.sparx.Repository();
    
         System.out.println("Repository: " + args[0]);
         System.out.println("Package:    " + args[1]);
         System.out.println("Output:     " + args[2]);
         r.OpenFile(args[0]);
         r.GetProjectInterface().RunHTMLReport(args[1], args[2], "GIF", "", ".html");
         r.CloseFile();
        }
    }
    

提交回复
热议问题