活动图并发语义代码自动生成算法设计
CSTR:
作者:
作者单位:

作者简介:

吴翔虎(1968—),男,教授; 李建中(1950—),男,教授,博士生导师.

通讯作者:

中图分类号:

TP311

基金项目:

国家高技术研究发展计划资助项目(2005AA742013).


Design of automatic code generation algorithm based on concurrency semantics of activity diagrams
Author:
Affiliation:

Fund Project:

  • 摘要
  • |
  • 图/表
  • |
  • 访问统计
  • |
  • 参考文献
  • |
  • 相似文献
  • |
  • 引证文献
  • |
  • 资源附件
  • |
  • 文章评论
    摘要:

    针对活动图能够比状态图更自然和直观地显示程序的并发行为,为达到图形化描述程序的并发行为并自动生成代码的目标,通过分析活动图的图元语义,以fork、join、activity、initial、activity final、flow final等6个图元作为图形建模和代码生成的基础,提出了一套代码自动生成算法.该算法把活动图拆分成若干独立的活动子图;再把每个活动子图解析成若干进程和信号量;最后对每一个进程和信号量进行代码生成.实验证明,基于本算法开发的原型系统取得了较满意的效果,同时也证明了所提出的方法和算法的正确性、有效性.

    Abstract:

    Compared with state diagram, activity diagram can be used to display the concurrent behavior of program in a more natural and intuitive way. Six primitives of initial, fork, join, flow final, activity final and activity were selected as the basis for graphical modeling and automatic code generation. A XML document format was defined to describe the activity diagram, then the XML document was parsed based on DOM, after that original activity diagram was split into separate activity sub-diagrams; and then each activity diagram was parsed into a number of processes and semaphores and codes. The methods and algorithms proposed were tested by designing and implementing a software system and good results were achieved, it showed that the methods and algorithms were right and effective.

    参考文献
    相似文献
    引证文献
引用本文

吴翔虎,曲明成,李建中,王志超.活动图并发语义代码自动生成算法设计[J].哈尔滨工业大学学报,2012,44(9):85. DOI:10.11918/j. issn.0367-6234.2012.09.015

复制
相关视频

分享
文章指标
  • 点击次数:
  • 下载次数:
  • HTML阅读次数:
  • 引用次数:
历史
  • 收稿日期:
  • 最后修改日期:
  • 录用日期:
  • 在线发布日期: 2012-09-27
  • 出版日期:
文章二维码