欢迎访问铁路通信信号工程技术,今天是 English

铁路通信信号工程技术 ›› 2023, Vol. 20 ›› Issue (10): 48-51.DOI: 10.3969/j.issn.1673-4440.2023.10.009

• • 上一篇    下一篇

基于AOP的动态数据翻译框架

张 舒   

  1. 北京全路通信信号研究设计院集团有限公司,北京 100070
  • 收稿日期:2022-05-05 修回日期:2023-09-07 出版日期:2023-10-25 发布日期:2023-10-25
  • 作者简介:张舒(1990—),女,工程师,硕士,主要研究方向:铁路运输指挥调度,邮箱:zhangshu@crscd.com.cn。

Translation Framework of Dynamic Data Based on AOP

Zhang Shu   

  1. CRSC Research & Design Institute Group Co., Ltd., Beijing 100070, China
  • Received:2022-05-05 Revised:2023-09-07 Online:2023-10-25 Published:2023-10-25

摘要: 软件市场国际化进程不断加快,动态数据翻译工作日益重要。设计一种通用动态数据翻译框架,采用AOP的切面技术进行翻译功能的织入,自定义注解用于标记具有翻译需求的方法和字段,使用翻译内容和唯一键值的方式满足交互数据的唯一性,双向翻译功能保证翻译与业务解耦。此方案已经实现并且应用到了海外铁路信息项目,满足多语言的翻译需求,且其可移植性和高可复用性极大提高开发效率。

关键词: AOP, 动态数据, 翻译框架, 国际化

Abstract: As the internationalization of the software market is accelerating, the translation of dynamic data is increasingly important. In the general-purpose translation framework of dynamic data designed in this paper, the following methods are adopted. The aspect-oriented technology AOP is used to weave the translation function. The customized annotations are used to mark the methods and fields with translation requirements. The translation contents and unique key values are used to meet the uniqueness requirement of interactive data. The two-way translation function is used to ensure the decoupling between translation and services. The proposed translation framework has been implemented and applied to railway information system projects in the overseas market. It not only meets the needs of multilingual translation, but also greatly improves the development efficient thanks to its portability and high reusability.

Key words: AOP, dynamic data, translation framework, internationalization

中图分类号: