作者投稿和查稿 主编审稿 专家审稿 编委审稿 远程编辑

计算机工程 ›› 2008, Vol. 34 ›› Issue (23): 47-49. doi: 10.3969/j.issn.1000-3428.2008.23.018

• 软件技术与数据库 • 上一篇    下一篇

一种新的具适应性的程序结构

杨志辉1,2,王小民1,2,张 雄1,2,许满武1,2   

  1. (1. 南京大学软件新技术国家重点实验室,南京 210093;2. 南京大学计算机科学与技术系,南京 210093)
  • 收稿日期:1900-01-01 修回日期:1900-01-01 出版日期:2008-12-05 发布日期:2008-12-05

New Adaptive Program Structure

YANG Zhi-hui1,2, WANG Xiao-min1,2, ZHANG Xiong1,2, XU Man-wu1,2   

  1. (1. State Key Laboratory for Novel Software Technology, Nanjing University, Nanjing 210093; 2. Department of Computer Science and Technology, Nanjing University, Nanjing 210093)
  • Received:1900-01-01 Revised:1900-01-01 Online:2008-12-05 Published:2008-12-05

摘要: TRAP/J结构可以将可适应性透明地加入已有的应用程序中,不用修改应用程序源代码和虚拟机。该文提出一种新的具适应性的结构,采用包装类和AspectJ获得对原类的封装和替代,使用抽象类代表原类,避免了原结构反射的使用。实验表明,与TRAP/J相比,用该结构构成的程序在单机环境中执行速度更快,但是在网络环境下两者相当。

关键词: 适应性软件, 组合适应, 面向方面编程, 面向对象编程

Abstract: TRAP/J is a structure which can add adaptive capacity into original existed application(without modification of source code and virtual machine). This paper proposes a new architecture of adaptive Java program. Wrapper class and AspectJ are applied to enclose and replace original class, and abstract class is applied to represent original class. Experiments show that compared with TRAP/J, the running speed of program with new architecture is higher within single computer, but within networks there is no remarkable difference between two architectures.

Key words: adaptive software, compositional adaptation, aspect-oriented programming, object-oriented programming

中图分类号: